About the function NCONC in Common Lisp

827 views Asked by At

I got a real stack overflow by typing the following codes

(setf l1 (list 1))

(setf l2 (list 2))

(nconc l1 l2)

(nconc l2 l1)

Oops...

Is that a bug?

1

There are 1 answers

0
Vatine On BEST ANSWER

Not as such. Printing a never-ending list won't ever be a good thing.

Set *print-circle* to T to see the structure of the list.

It's no more a bug than the never-ending nature of #1=(foo . #1#)