From: Ludwig N. <l-...@us...> - 2004-08-14 22:17:18
|
Steven Hartland wrote: > No u cant use arbitrary parameter numbers even though its in > the c89 standard MS hasn't adopted it yet. That cannot be the case otherwise you wouldn't even have printf. The variadic macro might be gcc specific but variadic functions aren't. You lose the file, line and function tags without the macro of course but apart from that I would expect it to work. > I committed a version that works for both gcc and ms vc friday night > although it does just disable debugging for win32 totally as the > comment said. Didn't have time to investigate an alternative sorry That's fine. No problem as long as it works on Linux :-) > although I suspect its not possible to fix without something silly like > debug(X) _debug( a, b, c, X); > and altering the calls to: > debug( ( z, x, z ) ); > which may then work but not sure. > Interestingly I never got a warning with gcc at all which version > you using? Ok under both the following here: > gcc version 2.95.4 > gcc version 3.3.3 gcc (GCC) 3.3.3 (SuSE Linux) issues warnings like that: qstat.c:5936: warning: left-hand operand of comma expression has no effect if you use '#define debug 0 &&'. cu Ludwig -- (o_ Ludwig Nussel //\ ICQ: 52166811 V_/_ PGP Key: FF8135CE |