Questions tagged [clisp]

GNU CLISP is an UNIX/Windows implementation of ANSI Common Lisp with many extensions.

GNU CLISP is a Common Lisp implementation. It implements the language described in the ANSI Common Lisp standard with many extensions, and runs on most UNIXes and on Microsoft Windows. It has an interpreter, a compiler, a debugger, and implements most features expected of a modern Common Lisp, including CLOS, MOP, an FFI, Perl and Posix regexes, and others.

GNU CLISP is distributed under the GNU GPL, but its copyright file specifies that it can be used to compile proprietary applications.

457 questions
59
votes
6 answers

Lisp Executable

I've just started learning Lisp and I can't figure out how to compile and link lisp code to an executable. I'm using clisp and clisp -c produces two files: .fas .lib What do I do next to get an executable?
Alexander Stolz
  • 7,454
  • 12
  • 57
  • 64
52
votes
2 answers

What's difference between defvar, defparameter, setf and setq

I found a Similar question. But I don't quite understand that explanation. So I'm trying to run clisp with the following example: [1]> (defvar a 5) A [2]> (+ a 1) 6 [3]> (defparameter b 5) B [4]> (+ b 1) 6 [5]> (setf c 5) 5 …
sam
  • 2,049
  • 3
  • 20
  • 27
27
votes
3 answers

What are the main differences between CLISP, ECL, and SBCL?

I want to do some simulations with ACT-R and I will need a Common Lisp implementation. I have three Common Lisp implementations available: (1) CLISP [1], (2) ECL [1], and (3) SBCL [1]. As you might have gathered from the links I have read a bit…
lord.garbage
  • 5,884
  • 5
  • 36
  • 55
21
votes
4 answers

Integer division in Common Lisp?

When I do (/ 7 2), what should I do to get the result 3? If I do (/ 7 2.0), I get 3.5, which is as expected.
appusajeev
  • 2,129
  • 3
  • 22
  • 20
19
votes
1 answer

Writing lambda expressions in common lisp

I am currently reading ANSI Common Lisp by Paul Graham, and I have a question about writing lambda expressions. Do we need to prefix a lambda expression with #'?. If I write something like this in REPL, it will work fine > ((lambda (x) (+ x 1)) 1) …
turingcomplete
  • 2,128
  • 3
  • 16
  • 25
18
votes
2 answers

Can I save source files in Clisp?

I'm a beginner programmer and am going through the book "Land of Lisp". I have been typing in the examples from the book with the REPL. Is it possible to save my current program as a .lisp file so I can load it and continue working on it later? I…
MikeJerome
  • 660
  • 6
  • 20
15
votes
5 answers

How to change SBCL's current directory?

It is very easy to change CLisp's current working directory: >cat ~/.clisprc.lisp ;;; The following lines added by ql:add-to-init-file: #-quicklisp (let ((quicklisp-init (merge-pathnames "quicklisp/setup.lisp" (user-homedir-pathname)))) (when…
z_axis
  • 8,272
  • 7
  • 41
  • 61
14
votes
1 answer

Lisp simple question

I have some not understanding actions from gnu clisp Suppose, I have some code like (let ((x "Hi!"))(print x)). If I execute it from console (like, clisp fileName.lisp) I see Hi! But, when I execute it from interpreter, I see this text twice.…
Stan Kurilin
  • 15,614
  • 21
  • 81
  • 132
13
votes
3 answers

Apache + mod_lisp + clisp

How to to configure apache + mod_lisp + clisp and set up a "Hello World!"? I couldn't find any complete howto on the subject. Thanks. Edit: Vebjorn's solution works, but then I don't how to code the "hello world!". Can anyone tell me how to proceed?…
Gra
  • 1,542
  • 14
  • 28
12
votes
3 answers

Lisp code called from Java

Long story: I am doing a project for my functional programing class, and I thought of writing an AI controller in Lisp, for the Mario AI competition. I was looking over frameworks/libraries/ways of calling Lisp code from Java, or even better…
florin.bunau
  • 1,875
  • 3
  • 17
  • 25
10
votes
2 answers

Land of Lisp example redundency?

I've read a lot of good things about Land of Lisp so I thought that I might go through it to see what there was to see. (defun tweak-text (lst caps lit) (when lst (let ((item (car lst)) (rest (cdr lst))) (cond ; If item =…
cwallenpoole
  • 79,954
  • 26
  • 128
  • 166
10
votes
2 answers

How is the defun macro implemented in lisp?

I'd like to learn more about lisp macros and I want to create a simple implementation of the defun macro. I'm also interested in lisp's source code in all the implementations.
Denis Nutiu
  • 1,178
  • 15
  • 22
10
votes
1 answer

Which IDE are CLISP Programmers using?

I noticed how SLIME (lisp development package for Emacs) does not come with a frame-source-location function for CLISP, so you can't automagically jump to a source location when inside the debugger. Given that, I figured CLISP users must be using…
MHOOO
  • 633
  • 6
  • 15
10
votes
4 answers

Stack overflow from recursive function call in Lisp

I am learning Lisp from the book "The Land of Lisp" by Conrad Barski. Now I have hit my first stumbling block, where the author says: Calling yourself in this way is not only allowed in Lisp, but is often strongly encouraged after showing the…
mydoghasworms
  • 18,233
  • 11
  • 61
  • 95
9
votes
7 answers

Which command could be used to clear screen in CLISP?

Such as cls for cmd.exe. It's very annoy if I can't do this.
Thomson
  • 20,586
  • 28
  • 90
  • 134
1
2 3
30 31