lkml.org 
[lkml]   [2004]   [Apr]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] Fix thinkos in #if -> #ifdef conversions
From
Date
On Tue, 27 Apr 2004 12:24:09 PDT, Tom Rini <trini@kernel.crashing.org>  said:
> <donning brown paper bag>
> When I changed some '#if FOO' tests to '#ifdef FOO' I forgot to make
> sure that nothing was doing #define FOO 0. So after auditing all of the
> changes I made, the following is needed:

You're not the first to do that - I stayed away from preprocessor variables
other than CONFIG_* when I chunked through a big #if/#ifdef cleanup a few
months ago, simply because my poor brain was too tiny to figure out what was
intended.

Oddly enough, all the abuses I gave up on trying to figure out were
of the form '#if FOO_DEBUG > N', while the non-debugging comparisons
in a #if were all fairly clear. That says something about kernel programmers,
but I'm not sure what.. :)

[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2005-03-22 14:02    [W:0.031 / U:0.184 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site