3 ms·
> because lazy sequences are supported throughout the language. Most of the time Lisp implements these data structures themselves - many/most Lisps are largely
by lispm 8y ago
> because lazy sequences are supported throughout the language.
Most of the time Lisp implements these data structures themselves - many/most Lisps are largely implemented in itself. As such Lisp exposes and provides very low-level data structures like conses, which are simply two element cells. Basically Lisp here is on the level of assembler - which is reflected that the historical name CAR means something like 'contents of the address register'.
Clojure's persistent immutable sequences are a very different data structure. Clojure does not expose its implementation and the implementation does not easily map to hardware, especially since quite a bit of the language is implemented in terms of the JVM and the Java language.
Example:
https://github.com/clojure/clojure/blob/master/src/jvm/clojure/lang/PersistentList.java https://github.com/clojure/clojure/blob/master/src/jvm/cloju...