Re: GHC API (parsing)

2008-04-14 Thread Niklas Broberg
how can I convince the Language.Haskell.Parser to accept GHC Haskell (i.e., -fglasgow-exts, e.g. for existential types) You use my haskell-src-exts package instead. :-) http://hackage.haskell.org/cgi-bin/hackage-scripts/package/haskell-src-exts-0.3.3 Cheers, /Niklas

GHC API (parsing)

2008-04-14 Thread Johannes Waldmann
Dear all, how can I convince the Language.Haskell.Parser to accept GHC Haskell (i.e., -fglasgow-exts, e.g. for existential types) or: how can I convince the GHC API loader to parse a module from a string (not from a file)? Any hints appreciated, Johannes.

Re: GHC API (parsing)

2008-04-14 Thread Johannes Waldmann
http://hackage.haskell.org/cgi-bin/hackage-scripts/package/haskell-src-exts-0.3.3 interesting, I'll look into that. * it's not exactly a drop-in replacement for Language.Haskell.* ? (HsNewTypeDecl is different?) * for the others, number of constructor arguments does not match, e.g.

Re: GHC API (parsing)

2008-04-14 Thread Niklas Broberg
* it's not exactly a drop-in replacement for Language.Haskell.* ? (HsNewTypeDecl is different?) * for the others, number of constructor arguments does not match, e.g. `HsConDecl' should have 2 arguments, but has been given 3 Indeed it is like you say, these are pragmatic choices. The

Re: GHC API (parsing)

2008-04-14 Thread Claus Reinke
general question * is there any parser that keeps comments (i.e. makes AST nodes from them)? what parser does Haddock use? you might want to add your voice and cc to Ticket #1886 ;-) GHC API should preserve and provide access to comments http://hackage.haskell.org/trac/ghc/ticket/1886 claus

Re: GHC API (parsing)

2008-04-14 Thread Marc Weber
GHC API should preserve and provide access to comments http://hackage.haskell.org/trac/ghc/ticket/1886 What does this lead to? Introspection? So you can get haddock comments from ghci? This would be interesting Marc Weber ___ Glasgow-haskell-users

Re: GHC API (parsing)

2008-04-14 Thread Johannes Waldmann
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Introspection? So you can get haddock comments from ghci? see also http://hackage.haskell.org/trac/ghc/ticket/2168 best regards, j.w. -BEGIN PGP SIGNATURE- Version: GnuPG v2.0.4-svn0 (GNU/Linux) Comment: Using GnuPG with Mozilla -