4 ms·
That’s because Python is a bad language for writing parser combinators and parsers based on them. Try Haskell.
by kccqzy 10mo ago
That’s because Python is a bad language for writing parser combinators and parsers based on them. Try Haskell.
- cipherself 10mo agoI have written parsers using parser combinators in Haskell and Clojure. I find that ML-like (Haskell, OCaml, StandardML) languages generally are great at writing parsers, even hand-written ones in it is a superior experience. In this case, this was a project at $EMPLOYER in an existing codebase with colleagues who have never seen Haskell code, using Haskell would've been a major error in judgement.
- eru 10mo agoI agree! Haskell is a great language. It can even be a great language for beginners, especially if there's some senior help on hand. But it's a terrible language to foist upon an unsuspecting and even unwilling victim.