Tom's Lisp

Lisp is an old dynamically-typed functional language. There are many dialects of lisp available, but for this class, we'll use TomsLisp, a very simple lisp that I wrote. The current version is 0.97

You can run tomslsp on Sandbox (account for the asking), or install it on a number of other platform, as follows. Note that Tom's Lisp is the command-line interpreter; you'll have to bring your own favorite text editor to make code files.
  • To install on RPM-based Linux systems, such as RedHat, download the RPM file tomslsp-0.97-1.x86_64.rpm. The command-line installation is dnf install tomslsp-0.97-1.x86_64.rpm (or possibly yum instead of dnf). Clicking on the file might work, too.
  • To install on Debian-based Linux systems, such as Ubuntu, download the DEB file tomslsp_0.97-1.deb. The command-line installation is apt install ./tomslsp_0.97-1.deb. Clicking on the file might work, too.
  • To install on Windows, you can use the Windows installer, tomslspinstall.exe. Download and run, confirm about 142 times that you really do want to install the program. You'll have an (ugly default) icon to run the interpreter. The load function searches for files on your desktop. You can edit files with Notepad, or any more-advanced text editor you might have available. Make sure to save them as plain text.
  • Alternatively, you can just download tomslsp.exe and tomsinit.lsp and store them both on your desktop. The exe should run fine from there.

  • The source package, tomslsp-0.97.tgz (or tomslsp-0.97.zip) should build on any Unix-like system with a proper C++ stack installed. Unpack and make. The default build depends on the gmp package for unbounded integer arithmetic, but you can build with make systemint and skip that.

    Without GMP, Tom's depends only the standard C++ libraries, and interacts with the OS only for standard I/O services, so you should be able to build it on anything where C++ works. Just unpack it, go there, and say c++ -o tomslsp *.cpp should work fine. The only issue is that, when the executable first starts, it must find and load the tomsinit.lsp file. It searches some reasonable places depending on the OS, or follows the environment variable LSP_PATH. Or just make sure tomsinit.lsp is in your working directory.

There is some older documentation here. It needs some updating to cover a small number of additions, but what's there is still correct, but we won't really get far enough into it for that to matter.