且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

在我的linux机器上安装lisp

更新时间:2023-11-19 21:03:10

安装并学习以下内容:

  • SBCL编译器

http://www.sbcl.org/platform-table.html安装二进制文件一旦习惯了,请从源代码进行编译,并保留源代码.这样,您可以轻松地通过M-跳转到SBCL的功能定义.在Emacs中.

install a binary from http://www.sbcl.org/platform-table.html Once your used to it, compile from source and keep the source around. This way you can easily jump to the definitions of functions of SBCL with M-. in Emacs.

  • Emacs

观看此截屏视频,看看有人实现了光线追踪器在通用Lisp中使用光线追踪器

watch this screencast to see someone implementing a raytracer Raytracer in Common Lisp

这是新的软件包管理.当我开始时,它不在那儿.现在我们有了它,您应该使用它.它使事情变得容易得多. 运行'sbcl --load quicklisp.lisp',然后输入(quicklisp-quickstart:install),按Enter键 然后运行(ql:add-to-init-file)

This is the new package management. When I started it wasn't there. Now we have it and you should use it. It makes things a lot easier. Run 'sbcl --load quicklisp.lisp' and then enter (quicklisp-quickstart:install) press enter and then run (ql:add-to-init-file)

  • SLIME在Emacs中运行.

  • SLIME runs within Emacs.

尝试使用quicklisp安装它.阅读其手册,找出要写入.emacs文件的内容,以便在打开Lisp文件时它会自动启动. (可选)观看截屏视频.

Try installing it with quicklisp. Read its manual and figure out what to write into your .emacs file so that it automatically starts when you open a lisp file. Optionally watch a screencast.

Paredit

认真地,您必须学习这一点(即使光线跟踪截屏中的那个人没有使用它).您应该以(开头,这将带有两个括号.使用M-(您可以将现有的s表达式括起来.C-k会将s表达式切入光标后面,而使用C-y则可以将其插入任何位置.

Seriously, you have to learn that (even if the guy in the raytracing screencast didn't use it). You should start with ( , this will make two parenthesis. With M-( you can enclose an existing s-expression. C-k cuts the s-expression behind the cursor and with C-y you can insert it anywhere.

  • ASDF

这是Lisp的品牌.您应该学习如何在ASDF文件中定义系统.

This is the make for lisp. You should learn how to define a system in an ASDF file.

  • 参考

我印了这本小册子 Common Lisp快速参考.非常简洁.

I printed this booklet, Common Lisp Quick Reference. It's very concise.