I come from a background in Haskell, and I want to learn Common Lisp.
It's well discussed that CL is "not a functional language", but I would like to know whether it can be used as a functional language.
For example, is it possible to use all of the data types in an immutable manner? Common Lisp hash-tables seem to be set using setf
, which is decidedly of the mutable orientation. Is there a way to use it in an immutable manner?
Aside from the "IO" aspect of Common Lisp (the "purely" aspect of Haskell) where I interact with files, networks, etc., can I comfortably write code in Lisp and be assured that the code will have referential transparency?
Can I expect these kinds of properties from the popular libraries available in Common Lisp?
Are there common idioms or aspects of the language that will make these difficult?