Thanks!
 
Any results on the Mac CW? What about other versions?
 
If the workaround works on all CW versions (I'd assume that they use the same preprocessor code on every compiler), I'll commit this change to the tuple header:
 
diff -r1.2 tuple.hpp
49c49,55
< #define BOOST_PREPROCESSOR_TUPLE_ELEM_DELAY(N,I,T) BOOST_PREPROCESSOR_IDENTITY(BOOST_PREPROCESSOR_TUPLE##N##_ELEM##I T)()
---
> #if defined(__MWERKS__) && __MWERKS__ <= 0x2405
> // This is a workaround for a CodeWarrior preprocessor bug. Strictly speaking
> // this workaround invokes undefined behavior, but it works as desired.
> #  define BOOST_PREPROCESSOR_TUPLE_ELEM_DELAY(N,I,T) BOOST_PREPROCESSOR_TUPLE##N##_ELEM##I##T
> #else
> #  define BOOST_PREPROCESSOR_TUPLE_ELEM_DELAY(N,I,T) BOOST_PREPROCESSOR_IDENTITY(BOOST_PREPROCESSOR_TUPLE##N##_ELEM##I T)()
> #endif
 
----- Original Message -----
From: Chris Little
To: 'boost@yahoogroups.com'
Sent: Monday, December 03, 2001 22:34
Subject: RE: [boost] Preprocessor workaround for CodeWarrior

> -----Original Message-----
> From: Vesa Karvonen [mailto:vesa.karvonen@housemarque.fi]
> Sent: Monday, December 03, 2001 2:41 PM
> To: boost@yahoogroups.com
> Subject: [boost] Preprocessor workaround for CodeWarrior
>
>
> Hi,
>
> Could someone with access to CodeWarrior (7.0) (PC &| Mac)
> compiler try the following workaround. I have access to
> "CodeWarrior for Palm OS Platform 7.0", but I do not have
> access to other versions. I know that it invokes undefined
> behaviour, but it is simple and it seems to work on that
> particular compiler.
>
> Change line 49 of boost\preprocessor\tuple.hpp to:
>
> #define BOOST_PREPROCESSOR_TUPLE_ELEM_DELAY(N,I,T)\
>   BOOST_PREPROCESSOR_TUPLE##N##_ELEM##I##T
>
> Regards,
>   Vesa Karvonen

With this change preprocessor_test.cpp compiles and runs fine under CWP 7 on PC.  I will try in on my Mac later.

Chris


Info: http://www.boost.org  Unsubscribe: <mailto:boost-unsubscribe@yahoogroups.com>

Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.