Parsec => libraries

Alastair Reid reid@cs.utah.edu
27 May 2002 19:47:03 +0100


This reminds me...

I like to give the operations in parsers the same name as the
corresponding operation in Pretty.  For example:

  Pretty.int :: Int -> Doc
  Parser.int :: Parser Int

I like the symmetry it gives the parser and unparser but, since this
punning can't readily be encoded as type classes it is more cosmetic
than useful.  

Any opinions about whether we should try to drift in this direction
with parsing stuff?

The obvious disadvantage is that you have to put your parser and
prettyprinter in separate modules - a structure I sometimes like and
sometimes hate.

-- 
Alastair Reid        reid@cs.utah.edu        http://www.cs.utah.edu/~reid/