3 ms·
Femtolisp is a very small, fast Scheme implementation – and Scheme is the most thoroughly standardized dialect of Lisp there is. The fact that Julia's parser is
by StefanKarpinski 12y ago
Femtolisp is a very small, fast Scheme implementation – and Scheme is the most thoroughly standardized dialect of Lisp there is. The fact that Julia's parser is implemented in flisp also completely irrelevant to the user – you can for all purposes just consider it a C program that implements a custom parser for Julia. It's true that there isn't a formal grammar specification of Julia's grammar, but I'm not sure what that would be especially useful for.
- cwp 12y agoIt would be useful for implementing Julia parsers.
- StefanKarpinski 12y agoThat's true but I'm not sure how many of those one wants until the language reaches a 1.0 version.
- Guthur 12y ago"...Scheme is the most thoroughly standardized dialect of Lisp there is" More standardized that ANSI Common Lisp, hint it's in the name. </facetious-reply>
- jahewson 12y agoBut Femtolisp isn't Scheme, it's a non-standard Scheme with its own custom built-ins. It's quite impossible to run a Femtolisp program using a Scheme interpreter without modification. Formal grammars are enormously useful, I almost always refer to them at some point when learning a language. It's an important part of being in an ecosystem larger than oneself. I'd question how a language without a well defined grammar has well defined semantics as the OP claims. How many languages have you learned the syntax of by reading the source code of its parser? How about when the parser is implemented on a language you've never used?
- StefanKarpinski 12y agoLearning a programming language by looking at the formal grammar is like learning a spoken language just by reading a grammar textbook. No one actually does that. Learning a language by reading the parser is even more ridiculous. That's like learning a spoken language by dissecting the brain of a native speaker. The way people actually learn languages – both programming and natural – is by seeing examples, reading explanations, and by trying things out.