Guile 和 Emacs?

发布于 2024-08-09 06:15:53 字数 443 浏览 6 评论 0原文

我正在学习 Emacs Lisp,我看到这篇十年前的帖子,说在某个时候 Guile (Scheme) 将取代 Emacs Lisp,或者 Emacs 将用 Guile 重写。

https: //web.archive.org/web/20081201143448/http://sanpietro.red-bean.com/guile/guile/old/3114.html

我想知道这是否仍然有可能,以及开发人员是否有可能应该考虑到这一点来尝试编写 Elisp 吗? Guile 最初的目标是向后兼容 Elisp,但现在看来开发 Scheme 是更好的选择。

I'm learning Emacs Lisp and I came across this decade old post saying that at some point Guile (Scheme) will replace Emacs Lisp, or Emacs will be rewritten with Guile.

https://web.archive.org/web/20081201143448/http://sanpietro.red-bean.com/guile/guile/old/3114.html

I was wondering if this is still a possibility, and if developers should be trying to write Elisp with this in mind? The original goal was for Guile to be backwards compatible with Elisp, but it seems like developing Scheme is the better choice.

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

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

发布评论

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

评论(6

酸甜透明夹心 2024-08-16 06:15:53

Guile 2.0 发布后应该可以在 Emacs 中使用 Guile。当前的预发行版支持 ecmascript 以及方案,并且显然还有一个 elisp 分支,但我还没有研究它。一旦 Guile 完全支持 elisp,用 Guile 替换当前的 elisp 解释器应该不会太难。真正的问题是人们是否会在方案中重写他们的自定义和附加组件,或者只是继续使用 elisp。无论如何,Guile 2.0 应该使 Guile Emacs 的可能性比过去 10 年来的任何其他开发更接近现实。

It should be possible after Guile 2.0 is released to use Guile with Emacs. The current pre-release supports ecmascript as well as scheme and there is apparently an elisp branch also but I haven't looked into it. Once Guile fully supports elisp it shouldn't be too hard to replace the current elisp interpreter with Guile. The real question is whether or not people are going to rewrite their customizations and add-ons in scheme or just continue to use elisp. Regardless, Guile 2.0 should make the possibility of a Guile Emacs much closer to reality than any other development in the past 10 years.

淡笑忘祈一世凡恋 2024-08-16 06:15:53

Guile 2.0.0(2011-02-06 发布)支持 Emacs Lisp。

你可以像这样在 repl 上切换:

 scheme@(guile-user)> ,language elisp
 Happy hacking with Emacs Lisp!  To switch back, type `,L scheme'.
 elisp@(guile-user)> (eq 1 2)
 $1 = #nil

至于是否/何时有人要在 Emacs 上做一些手术来提取 elisp 并放入 Guile-in-elisp-mode: Guile 2.0.2 参考手册表明这是计划,但尚未准备好:

我们希望最终 Guile 的
Elisp的实施会很好
足以替代Emacs自己的
Elisp 的实现。

Guile 2.0.0 (released 2011-02-06) supports Emacs Lisp.

You can switch at the repl like so:

 scheme@(guile-user)> ,language elisp
 Happy hacking with Emacs Lisp!  To switch back, type `,L scheme'.
 elisp@(guile-user)> (eq 1 2)
 $1 = #nil

As to if/when someone is going to do some surgery on Emacs to extract elisp and drop in Guile-in-elisp-mode: the Guile 2.0.2 reference manual suggests this is the plan but it's not ready yet:

We hope that eventually Guile's
implementation of Elisp will be good
enough to replace Emacs' own
implementation of Elisp.

永言不败 2024-08-16 06:15:53

再次使用 guile 和 emacs - 使用未破解的 Guile 更新了 Emacs src,2009 年 8 月 23 日

PS:我最近注意到我的第一个
提交到 Emacs 源代码树
与该项目相关的
1999年8月28日,距离十年前还差一点点。
我不确定我是否应该庆祝或者
周五心情郁闷。

http://lists.gnu.org/archive/html /guile-devel/2009-08/msg00163.html

guile and emacs, again - updated Emacs src, using non-hacked Guile, 23 Aug 2009

PS: I was noticing recently that my first
commit to the Emacs source tree
relating to this project was on
1999-08-28, just shy of ten years ago.
I'm not sure if I should celebrate or
be depressed on Friday.

http://lists.gnu.org/archive/html/guile-devel/2009-08/msg00163.html

苍白女子 2024-08-16 06:15:53

我不会对此太担心。有几个项目可以将 Guile 与 Emacs 一起使用,但我感觉它们不受主线支持。正如其中一个项目的开发人员所观察到的那样,除非所有现有的 elisp 在新引擎中完美运行,否则没有人会切换,这是一项相当艰巨的任务。

并不是说它永远不会发生,它只是“在云端”已经有几年了。

I wouldn't worry too much about it. There are a couple of projects to use Guile with Emacs, but I sense that they're not mainline supported. As one of the developers of one of the projects observed, no one will switch unless all their existing elisp runs flawlessly in the new engine, which is a pretty tall task.

Not that it will never happen, it's just been 'in the clouds' for a few years.

江挽川 2024-08-16 06:15:53

使用像 parrot 这样的 VM 似乎比 Guile 更有趣,因为 Parrot VM 可以处理 许多不同的动态语言,每种语言都可以重用用另一种语言开发的内容。

剩下要做的工作是:

  • 向 Parrot VM 添加 emacs 低级概念和功能(基本 elisp 类型,如缓冲区类型、窗口、框架...),
  • 为 Parrot VM 创建 elisp 语言端口。

借助这些功能,您可以在 Parrot VM 上运行所有旧版 elisp 代码,而不会出现任何移植问题,并且可以通过 Parrot VM 支持的任何语言来开发和重用新代码。

Using a VM like parrot seems more interesting for the future than Guile as Parrot VM can handle many different dynamic languages and each language can reuse what has been developed in another language.

The work left to be done is :

  • adding emacs low-level concepts and functions to Parrot VM (basic elisp types like the buffer type, window, frame...)
  • creating an elisp language port to Parrot VM.

With such functionalities you could have all legacy elisp code running on Parrot VM without any porting issues, and new code could be developed and reused by any language supported by Parrot VM.

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