4 ms·
The formal Scheme syntax spec is, what?, a few pages. Far smaller than any other "real" language I'm aware.
by ChrisSD 6y ago
The formal Scheme syntax spec is, what?, a few pages. Far smaller than any other "real" language I'm aware.
- garmaine 6y agoReal schemes are much more complicated. I think he’s talking about Common Lisp though.
- EE84M3i 6y agoI'm not too familiar with scheme, but syntax seems to be at least a few dozen pages here? www.r6rs.org/final/r6rs.pdf Also compare https://people.csail.mit.edu/jaffer/r5rs_9.html https://people.csail.mit.edu/jaffer/r5rs_9.html and e.g. https://docs.python.org/3/reference/grammar.html https://docs.python.org/3/reference/grammar.html which I would consider a relatively syntactically rich language.
- shakna 6y agoR6RS was the largest Scheme spec ever, and because of it the next one was actually reduced into two: R7RS-small (core-language) and R7RS-big (extended). The R7RS-small standard [0] has already been ratified. It is a similar size to R6RS as a document size, but the semantics are about 8 pages, and include a bunch of macros that you don't need to implement, but just copy and paste into your implementation. I'd say it's a similar sized grammar to Python's. [0] https://small.r7rs.org/attachment/r7rs.pdf https://small.r7rs.org/attachment/r7rs.pdf
- donio 6y agoWhat I see is that the Scheme one is a lot more thorough and still shorter.
- Wezl 6y agoI enjoy lisp/scheme syntax, but I'm especially impressed by lua's simple, readable, flexible, whitespace-insensitive-but-whitespace-friendly syntax. It is a bit more complicated than scheme's, but more intuitive because you don't need to explain quasi-quoting and other lisp-specific stuff. https://www.lua.org/manual/5.4/manual.html#9 https://www.lua.org/manual/5.4/manual.html#9