Re:What can we learn from how compilers are designed?
by blt on Friday March 16, 2018 @11:27PM
(#16605461)
The parser/lexer separation feels especially useless in a Lisp interpreter, where the parsing is trivial.
[ Parent
| on HN ]
Re:What can we learn from how compilers are designed?
by kazinator on Saturday March 17, 2018 @02:58AM
(#16605894)
It's there. E.g. ANSI Lisp has the concept of a token. Reading multiple objects until a closing ) via read-delimited-list is like parsing. The actions which accumulate token constituent characters into a token and produce some object from it, like a number or symbol, are like lexing.