4 ms·
CL, and its object system particularly, specifies a lot of extensibility and sometimes hilarious dynamicity with exacting detail. E.g. you can subclass a class
by pwpwp 14y ago
CL, and its object system particularly, specifies a lot of extensibility and sometimes hilarious dynamicity with exacting detail. E.g. you can subclass a class that doesn't even exist yet (!)
CL-USER> (defclass foo (bar) ())
#<STANDARD-CLASS FOO>
CL-USER> (find-class 'bar)
#<FORWARD-REFERENCED-CLASS BAR>
That's just one detail, but CL is chock full of such niceties, owing to the fact that a lot of rivaling factions of super-smart programmers wanted to get all their favorite features into it.
- lisper 14y agoReader macros are also very handy. This is a feature unique to CL.
- zephyrfalcon 14y agoThat doesn't seem correct. I know of at least two Scheme implementations that have reader macros (Racket and Chicken); there might be more. However, whether their reader macros are as powerful as CL's [1], I don't know. [1] as demonstrated e.g. here: http://letoverlambda.com/index.cl/guest/chap4.html http://letoverlambda.com/index.cl/guest/chap4.html
- lisper 14y agoThese are implementation-specific extensions, not part of Scheme. Scheme doesn't have e.g. a GUI either (neither does CL) notwithstanding that specific Scheme and CL implementations have GUIs. It's borderline trivial to add reader macros to any implementation of any dialect of Lisp, but only in CL can you count on having them available.
- KaeseEs 14y agoAre they coming to Clojure soon or did I misinterpret Rich Hickey's latest interview?
- snprbob86 14y agoHe was talking about "tagged literals", not general reader macros. See http://dev.clojure.org/display/design/Tagged+Literals http://dev.clojure.org/display/design/Tagged+Literals