Hello,<div><br></div><div>I find that parser correctness is often hard to verify.  Therefore, I&#39;m interested in techniques that others have used successfully, especially with Haskell.</div><div><br></div><div>Techniques I&#39;m aware of:</div>
<div>  * Round trip checks: Generate a datastructure, render as a string, parse back, and compare.  Quickcheck can be used to automate this.</div><div>  * Fuzz testing:  What tools exist to help me?</div><div>  * Formal verification: Has anyone been using this with Haskell parsers?  Other than general theorem provers, say Isabelle, what tools exist?</div>
<div><br></div><div>My specific need:</div><div>The immediate challenge I have is that I&#39;m modifying the parser that Darcs uses and we would like to improve the parser&#39;s test suite as well.  The parser abstraction used in this case follows parsec&#39;s API.  Left to my own devices I would use round trip checks, written with quickcheck, for this exercise.  Because we&#39;re using a parsec style parser, I don&#39;t have a nice neat grammar handy.</div>
<div><br></div><div>Thanks in advance for any advice you have!</div><div><br></div><div>Thanks,</div><div>Jason</div>