Pragma not recognised when wrapped in #ifdef

Brandon S. Allbery KF8NH allbery at ece.cmu.edu
Tue Feb 10 14:52:28 EST 2009


On 2009 Feb 10, at 8:55, Alistair Bayley wrote:
> Perhaps CPP shouldn't be a pragma, just a command-line flag? It seems
> to be the only one that affects/involves preprocessor(s). AFAICT, the
> others all affect the haskell compiler stage.


Or require the CPP pragma to be the first thing in the file,  
immediately triggering cpp and a reread.  This means

 > #if 0
 > {-# LANGUAGE CPP #-}
 > #endif

is ambiguous, but I think it could be argued that the programmer has  
asked for _|_ and any behavior is acceptable.

-- 
brandon s. allbery [solaris,freebsd,perl,pugs,haskell] allbery at kf8nh.com
system administrator [openafs,heimdal,too many hats] allbery at ece.cmu.edu
electrical and computer engineering, carnegie mellon university    KF8NH


-------------- next part --------------
A non-text attachment was scrubbed...
Name: PGP.sig
Type: application/pgp-signature
Size: 195 bytes
Desc: This is a digitally signed message part
Url : http://www.haskell.org/pipermail/glasgow-haskell-users/attachments/20090210/65020e59/PGP.bin


More information about the Glasgow-haskell-users mailing list