GNU Common Lisp is the GNU project's Common Lisp compiler. It's compliant with CLtL1 standard.
Questions tagged [gnu-common-lisp]
25 questions
6
votes
2 answers
GNU Common Lisp package implementing forkpty()
I seek a GNU Common Lisp package which implements forkpty(); openpty() would also be a big plus, and login_tty() would be a luxury I could live with. (Duckduckgo, Google, etc. were of no help.) Is there such? Where?

Bill Evans at Mariposa
- 3,590
- 1
- 18
- 22
6
votes
2 answers
How do I format a single backslash in common lisp?
I'm currently trying to get an output of ... \hline in GNU Common lisp 2.49, but I can't get the format to work. This is what I've tried so far to get a single backslash:
(format nil "\ ") => " "
(format nil "\\ ") => "\\ "
(format nil "\\\ ") =>…

iHowell
- 2,263
- 1
- 25
- 49
5
votes
2 answers
Determining a supertype path
Given a variable with content 1, I know that it's a member of at least five types:
1 (let* ((fred 1))
2 (princ (typep fred 'bit)) (terpri)
3 (princ (typep fred 'integer)) (terpri)
4 (princ (typep fred 'fixnum)) (terpri)
5 (princ (typep…

Bill Evans at Mariposa
- 3,590
- 1
- 18
- 22
5
votes
1 answer
Lisp : How do I install gcl in mac
I have Mac OSX 10.8.4. I have cloned the git repo of gcl and as per the readme I ran the ./configure.
But, I am getting the following error :
configure: error: Cannot build with randomized sbrk. Your options:
- upgrade to a kernel/libc that knows…

quickbrownfox
- 161
- 1
- 14
4
votes
2 answers
Details of GNU Common Lisp's (type-of)
If at the REPL I enter:
(type-of (make-array 5))
then I get the response:
(SIMPLE-VECTOR 5)
Fair enough. So if at the REPL I enter:
(type-of (make-array (list 5 3 2)))
then I get the response:
(SIMPLE-ARRAY T (5 3 2))
I have two…

Bill Evans at Mariposa
- 3,590
- 1
- 18
- 22
4
votes
1 answer
How can conditions be handled in GCL?
handler-case is key to handling conditions in Common Lisp, but GCL 2.6.12 on Ubuntu 18.04 considers it to be an undefined function:
>(handler-case (error "test") (error (condition) condition))
…

tangle
- 323
- 2
- 11
4
votes
2 answers
What is the difference between packages GCL and CLISP?
In the Ubuntu repositories there are two implementations of Lisp: GCL and CLISP. Is there a fundamental difference between them? Which one is closer to the industry standard?

Artur Olenberg
- 508
- 1
- 5
- 16
4
votes
1 answer
Collecting the time and space results produced by `time` macro?
Common Lisp provide a time macro for finding out how long a form takes to execute, and it prints the information to the trace output:
time evaluates form in the current environment (lexical and dynamic). … time prints various timing data and other…

Pankaj Sejwal
- 1,605
- 1
- 18
- 27
4
votes
5 answers
speeding up deleting duplicates when they're adjacent
I'm looking for something like #'delete-duplicates, but I know that all elements of the list are already sorted, or inversely sorted, or at least arranged so that duplicates will already be adjacent to each other. I wish to use that knowledge to…

Bill Evans at Mariposa
- 3,590
- 1
- 18
- 22
3
votes
2 answers
Can CONS objects be used as a key to a hash table?
I've been playing with LISP lately, and I want to attempted to optimize a terribly inefficient recursive function by caching it's output so it only runs each combination of parameters once. I want to save the results into hash table, using either…

Robbie Mckennie
- 405
- 2
- 16
3
votes
2 answers
How can I specify the package name when launching a Lisp program from the command line?
I'm calling a Lisp function (and a few other thing) from a shell script. For brevity, below is relevant part of the script :
./gcl -load /tmp/calendrica-3.0.cl -batch -eval '(format T "~a"
(CC3::sunset (CC3::fixed-from-gregorian…

GeneQ
- 7,485
- 6
- 37
- 53
2
votes
2 answers
GNU clisp: suppressing warning message about no-applicable-method
This code works as I want, except for the warning message. In GNU Common Lisp, how do I suppress that message without suppressing other possible warning messages?
1 (defgeneric zang (x y)
2 (:documentation "they want you to put documentation…

Bill Evans at Mariposa
- 3,590
- 1
- 18
- 22
2
votes
1 answer
How to trace in Common Lisp using gcl?
Is there some way to print out all the calls of your function to debug recursive programs?

user68322
- 29
- 3
2
votes
2 answers
Installing Quicklisp libraries in a Docker image
Is there a Dockerfile for installing cl-json (or other Quicklisp library) on Docker? Most installation instructions I've seen require user input on commands with no --noinput flag, making it difficult to install through a Dockerfile.
In addition,…

Will
- 1,171
- 2
- 14
- 26
2
votes
1 answer
Common Lisp: getting an error using readtable-case
When I enter this at the REPL prompt:
(setf (readtable-case *readtable*) :invert)
I get this error message:
Error in SETF [or a callee]: Cannot expand the SETF form (READTABLE-CASE
…

Roger Costello
- 3,007
- 1
- 22
- 43