
On Mar 26, 2008, at 7:42 , Bulat Ziganshin wrote:
Wednesday, March 26, 2008, 2:32:53 PM, you wrote:
I'm looking to parse a Fortran dialect using Parsec, and was
afair, some months ago BASIC parsing was discussed here.
the first solution one can imagine is to add preprocessing stage replacing line ends with ';'-alike
FWIW I just ignored the lexeme parser and did my own on top of the basic Parsec primitives. You may need to do that anyway if you want to support older variants of Fortran, which don't actually have keywords and ignore spaces outside of string constants (Hollerith constants) --- Parsec's lexeme stuff doesn't even pretend to support this. -- brandon s. allbery [solaris,freebsd,perl,pugs,haskell] allbery@kf8nh.com system administrator [openafs,heimdal,too many hats] allbery@ece.cmu.edu electrical and computer engineering, carnegie mellon university KF8NH