[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [RP] RATPOISON_DEBUG
From: |
Bernhard R. Link |
Subject: |
Re: [RP] RATPOISON_DEBUG |
Date: |
Wed Apr 14 01:07:02 2004 |
User-agent: |
Mutt/1.3.28i |
* twb <address@hidden> [040413 18:36]:
> Once in a while, as an intellectual exercise (and to remind me why I
> love RP so much), I try to compile Rayvtugrazrag 0.17 from CVS.
>
> While trying to resolve a dependency, I noticed this (paraphrased):
>
> Our debug macro:
> #define xdebug(fmt) do { printf fmt; fflush(stdout); } while(0)
>
> Their debug macro:
> #define xdebug(fmt, args...) do { printf(fmt, ## args; fflush(stdout);
> } while(0)
I think this is even dangerous if only using different versions of gcc.
To avoid problems with some versions (I do not remember which), it
should be "printf(fmt , ##", as ## sometimes is not specific to comata,
but deletes the whole last token, if the following list is empty.
Hochachtungsvoll,
Bernhard R. Link