"Dimitry Golubovsky" <[EMAIL PROTECTED]> wrote:

> Is this  a bug or a feature that cpphs does not pass the #pragma cpp
> directive (they disappear in the output)?

A feature I suppose.  At least, it was a deliberate design choice.  The
purpose of cpphs is to remove all # directives from the file, leaving
only Haskell (or plain text if you prefer).  Now I realise that this is
not entirely true, since cpphs _does_ leave #line droppings unless you
specify the --noline option.  But although most Haskell implementations
do read and use #line hints, I was not aware of any tools that make
further use of #pragma, and indeed quite the opposite - many tools break
if they see the latter.

> In version 0.6 of cpphs:
>     *  Recognise and ignore the #pragma cpp directive.
> 
> Or what command line options could be used to preserve #pragma's in
> cpphs output?

I am happy to add an option (--pragmas maybe?) to preserve #pragma if
there is user demand.  Check the cpphs darcs repository at
    http://www.cs.york.ac.uk/fp/darcs/cpphs
for new patches.

Regards,
    Malcolm
_______________________________________________
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to