News for hackers. Stuff that matters.
Re:So You Want to Write Your Own Language (2014) by musesum on Wednesday December 23, 2015 @04:33PM (#10785802)
> Regex is just the wrong tool for lexing and parsing

Funny; I recently wrote an Island parser that extends Regex to create a token stream: https://github.com/musesum/Par

Quoting the link to Rob Pike's post:

> Consider finding alphanumeric identifiers. It's not too hard to write the regexp (something like "[a-ZA-Z_][a-ZA-Z_0-9]*"), but really not much harder to write as a simple loop

Maybe I'm missing something, but does this suggest replacing a declaration with a procedure? Oh the horror!

There are no comments on this comment yet.