Sean Kelly wrote:
I've found that once I created one lexer it could be re-used pretty easily for other languages too. And recursive descent parsers are trivial to write. It may be overkill for command-line parameters, but for anything remotely structured it's generally worth using.
When I was looking into parsing date strings, I thought it would be much easier if I adopted a lex/parse style approach. The result is in std.dateparse. The payoff is I've had very little trouble with it.
