3 ms·
> What? You're going to hand code a lexer each time you need to parse a phone number or a zip code? If there was a better alternative we would be using it. Use
by lmm 6y ago
> What? You're going to hand code a lexer each time you need to parse a phone number or a zip code? If there was a better alternative we would be using it.
Use a parser combinator library. I've yet to find a case where they weren't a better replacement for regexes.