Re:Nom, a byte oriented, streaming, zero copy, parser combin...
by nickpsecurity on Tuesday May 26, 2015 @07:48PM
(#9608404)
That makes sense. The combinator approach might be verified using a form of design by contract or VCG's if it's simple functions. I'll look into them when I take the deep dive into functional programming.
Proving with Coq the soundness of a parser compared to its grammar is a cool approach! The biggest problem one has when writing parsers in "safe" systems like parser generators or parser combinators, is the gaps between the input language intended by the designer, the input language described by the grammar and the input language described by the code. Anything that can reduce those gaps is welcome.
I shoul try at some point to use Coq or some SMT based system to hunt ambiguity in formats. That would make an interesting research ;)