“swank-clojure”有什么作用?确切地说,我们有“swank-SOMETHING_ELSE”吗?

发布于 2024-09-15 07:20:26 字数 356 浏览 19 评论 0原文

我的肤浅理解是“swank-clojure”使“Mx slime-connect”成为可能。我的意思是,它提供了与 clojure 服务器的连接,例如“lein swank”。我的理解正确吗?如果不是,那么swank的目的是什么?

那么,是否有任何“swank-SOMETHING_ELSE”用于其他类似 lisp 的实现?例如,swank-clisp?

我需要“swank-clojure”才能将 SLIME/Clojure 与“Mx slime”一起使用吗?

添加

我发现这个链接非常有用。

My superficial understanding is that 'swank-clojure' makes 'M-x slime-connect' possible. I mean, it gives a connection to a clojure server something like 'lein swank'. Is my understanding correct? If not, what's the purpose of swank?

Then, is there any 'swank-SOMETHING_ELSE' for other lisp like implementations? For example, swank-clisp?

Do I need 'swank-clojure' for using SLIME/Clojure with 'M-x slime'?

ADDED

I found this link pretty useful.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(4

冰雪之触 2024-09-22 07:20:26

SLIME 和 swank 形成了一个客户端服务器架构来运行和调试 lisp 程序。 SLIME 是 emacs 前端,swank 是后端。在它们之间创建一个网络套接字并通过发送消息(S 表达式)进行通信。简而言之,它只是 emacs 和实际 Lisp 后端之间的 RPC 机制。

slime 和 swank 是分开的,通过网络连接并通过 rpc 消息进行通信,这意味着它们可以在任何地方。因此,slime 可以连接到远程主机/端口来进行炫耀。您看到的所有其他形式(lein swank 等)都会执行相同的操作。他们开始在允许远程连接史莱姆的端口上炫耀。

swank-clojure 是 swank 的 Clojure 端口。最初 swank-clojure 带有一个名为 swank-clojure.el 的辅助 elisp 文件。该文件的作用是手动设置 swank 参数,如类路径、jvm 参数等。由于后来出现了 lein 等其他工具,因此 swank-clojure.el 已被弃用。但它仍然存在于: http://github.com/vu3rdd/swank-clojure-extra< /a> 并提供 Mx swank-clojure-project,它可以在 lein 项目上启动 swank。

应该指出的是,SLIME 起源于(并且仍在积极开发)Common Lisp。事实上,swank 的 clojure 移植仅具有原始 SLIME/swank 版本所享有的功能的子集。 SLIME 存在于 Common Lisp 的所有主要变体中。它有一个针对Scheme48 的部分移植。 contrib 目录下有一些部分实现。

如果您知道 swank 已在端口上运行,请使用 slime-connect。如果您只想在项目中使用 slime,swank-clojure-project 和 lein swank 似乎是最佳选择。

SLIME and swank form a client server architecture to run and debug lisp programs. SLIME is the emacs frontend and swank is the backend. In between they create a network socket and communicate by sending across messages (S-expressions). In short it is just an RPC mechanism between emacs and the actual lisp backend.

The fact that the slime and swank are separate, are connected over a network and communicate via rpc messages means that they can be anywhere. So, slime can connect to a remote host/port to swank. All other forms you see (lein swank etc etc) do the same. They start swank on a port allowing for a remote connection of slime.

swank-clojure is the clojure port of swank. originally swank-clojure came with a helper elisp file called swank-clojure.el. The job of this file was to enable manual setup of swank parameters like the classpaths, jvm parameters etc. Since other tools like lein came along later, swank-clojure.el was deprecated. But it still lives on at: http://github.com/vu3rdd/swank-clojure-extra and provides the M-x swank-clojure-project which enables starting swank on a lein project.

It should be noted that SLIME originated in (and is still being actively developed for) Common Lisp. Infact, the clojure port of swank only has a subset of the features enjoyed by the original SLIME/swank versions. SLIME exists for all major variants of Common Lisp. There is a partial port of it for Scheme48. There are some partial implementations available under the contrib directory.

If you know that swank is already running on a port, use slime-connect. If you just want to use slime on a project, swank-clojure-project and lein swank seem to be the way to go.

别闹i 2024-09-22 07:20:26

swank-clojure.el 已弃用。不要使用它。

您需要 slime.el 并且需要在 project.clj 文件的开发依赖项中包含 swank-clojure "1.2.1"

Swank 基本上是一个使用 slime 从 emacs 连接到的服务器。它从 emacs 传递了您希望由它正在运行的 Lisp 进程运行的内容。

在使用 lein swank 启动后,您应该使用 Mx slime-connect 连接到 swank 服务器。

swank-clojure.el is deprecated. Don't use it.

You need slime.el and you need to have swank-clojure "1.2.1" in your dev-dependcies in your project.clj file.

Swank is basically a server that you use slime to connect to from emacs. It it passed, from emacs, what you want run by the Lisp process that it's running.

You should use M-x slime-connect to connect to a swank server after starting with with lein swank.

一张白纸 2024-09-22 07:20:26

Swank 是 swank 客户端的服务器版本,例如 emacs SLIME 和 Macintosh 的 MCLIDE lisp 开发环境。 Swank 服务器适用于许多 Common Lisp 实现和 Lisp 方言,例如 Clojure 和 Gambit/scheme。

Swank is the server counterpart to swank clients like emacs SLIME and the MCLIDE lisp development environment for Macintosh. Swank servers exist for many Common Lisp implementations and Lisp dialects such as Clojure and Gambit/scheme.

岛徒 2024-09-22 07:20:26

我的理解是,slime是emacs部分(客户端),swank是common lisp部分(服务器),swank-clojure是swank服务器的clojure实现,而不是原始的。

My understanding is that slime is the emacs part(the client), swank is the common lisp part(the server), swank-clojure is the clojure implementation of the swank server, not the original.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文