Re: check if program uses haskell 98 only? Re: [Haskell-cafe] regex package for yhc?

2007-12-06 Thread Henning Thielemann

On Thu, 6 Dec 2007, Thomas Hartman wrote:

 On a related note... is there some easy way to be sure that a program I am
 compiling uses only haskell 98? (Because any pure haskell 98 should always
 compile on yhc... right?)

You can for instance use 'haskell98' as dependent package instead of
'base' in the Cabal description. If you import other modules, I don't know
how to check that these are Haskell 98. I weakly remember corner cases
where GHC accepts more than Haskell 98 in Haskell 98 mode. (At least it
sometimes suggests fixes for errors that are not Haskell 98, e.g.  class
constraints in signatures. :-)

 I compile this with ghc, no options, and iIt doesn't have any {-#-#}
 options, so according to what I understand, it is using pure haskell 98.
 So I might think this was a candidate for using on yhc.

I could not always pass a GHC-certified module to Hugs or even Haddock. I
remember there is some difference with respect to the trailing 'where' in
the 'instance' head, if the instance declaration is empty.  Haddock expect
some spaces in infix operators (I believe ( # ) instead of (#)), which are
not required by Hugs and GHC.
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] regex package for yhc?

2007-12-06 Thread Duncan Coutts

On Thu, 2007-12-06 at 15:21 -0500, Thomas Hartman wrote:

 Is there a cabal equivalent for yhc?

One day we hope Cabal will support yhc. It currently supports ghc, hugs
and has partial support for nhc98 and jhc.

The main thing holding it back is dependency chasing in Cabal or the
lack thereof. Cabal relies on the build-in dep chasing in hugs, ghc
--make. It uses hmake for nhc98. We hope to replace this hodge-podge
with proper dependency chasing support in Cabal, that's also extend to
pre-processors etc. If anyone is interested in helping with this
project, subscribe to cabal-devel and get involved.

Duncan

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe