3 ms·
What I've done in my own implementation is include the line and column number in the token.
by pkaye 1y ago
What I've done in my own implementation is include the line and column number in the token.
- socalgal2 1y agoYea, that's what I assumed too but the article didn't include them and I assumed it was for speed reasons. I've run into this often where some idealized version doesn't take into account usage ergonomics. A compiler that can't tell me where an error is is not a useful compiler to me so if this lexer doesn't support that then it won't actually be a net positive in development speed for me. I fail compilation more often than I succeed.