4 ms·
How to implement a programming language in JavaScript
- billconan 7y agoin the link, the author says, don't use regexp for parser. is there any background on this? trying to understand the limitation of regexp.
- billconan 7y agook, I found something https://blog.codinghorror.com/parsing-beyond-regex/ https://blog.codinghorror.com/parsing-beyond-regex/ https://news.ycombinator.com/item?id=2915137 https://news.ycombinator.com/item?id=2915137
- galaxyLogic 7y agoSimple example: RegExp allows you to find the next closing parenthesis. But it can not "see" how many opening parenthesis there were before that. Therefore it can not tell you if the closing parenthesis it found is the "matching" closing parenthesis