Great! You are ahead of me. :) I will be testing the preprocessor on
various complex codes in the next days, so if I find any more problems I
will report them.

Thanks
Andreas

On 5/23/06, Hartmut Kaiser <hartmut.kaiser@gmail.com> wrote:

Andreas Sæbjørnsen wrote:

> Using the 'samples/cpp_tokens' example preprocessor with the
> following code:
>     #define true   1
>     #define false  0
> gives the following error:
>
> test.C(1): error: ill formed preprocessor directive: #define
>
> Preprocessing the same file with 'cpp' give no error. If any
> of the two lines in the file is removed the other line will
> cause an error. I guess the error occurs because 'true' is
> not an T_IDENTIFIER, but a T_TRUE. Could you imagine a clean
> fix to this issue?

You're right it's because T_TRUE and T_FALSE are not plain identifiers but
C++ keywords and the token category used by Wave does reflect that. This
problem additionally occurred at other places (such as #undef true) but all
of them are fixed in CVS now (CVS::HEAD and CVS::RELEASE_1_34). A
corresponding test case has been added.

Thanks for reporting!
Regards Hartmut



_______________________________________________
Boost-users mailing list
Boost-users@lists.boost.org
http://lists.boost.org/mailman/listinfo.cgi/boost-users