This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: new cpp preprocessor fails
- To: neilb at earthling dot net
- Subject: Re: new cpp preprocessor fails
- From: jarausch at igpm dot rwth-aachen dot de
- Date: Wed, 15 Nov 2000 09:54:10 +0100
- cc: gcc-bugs at gcc dot gnu dot org
- Reply-To: jarausch at igpm dot rwth-aachen dot de
On 14 Nov, Neil Booth wrote:
> Please provide all the macros needed to reproduce your result.
OK, I've boiled it down to
-------------------------------------------------------------------------------
#define UNUSED __attribute__((__unused__))
#define INLINE __inline__
# define INLINE_SIM_ENDIAN(TYPE) static INLINE TYPE UNUSED
#define M 8
INLINE_SIM_ENDIAN(unsigned_8) endian_t2h_8(unsigned_8 x);
#define T2H_8(X) endian_t2h_8(X)
#define CONCAT2(a,b) a##b
#define XCONCAT2(a,b) CONCAT2(a,b)
#define unsigned_M XCONCAT2(unsigned_,M)
#define T2H_M XCONCAT2(T2H_,M)
/* the following 2 lines are just a workaround */
typedef unsigned_M HJ_Type;
val = T2H_M (*( HJ_Type *) sim_core_translate (mapping, addr));
/* the following line expands to
val = endian_t2h_8(*(XCONCAT2(unsigned_,8)*) sim_core_translate (mapping,
*/
val = T2H_M (*(unsigned_M*) sim_core_translate (mapping, addr));
-------------------------------------------------------------------------------
--
Helmut Jarausch
Lehrstuhl fuer Numerische Mathematik
Institute of Technology, RWTH Aachen
D 52056 Aachen, Germany