lkml.org 
[lkml]   [2000]   [Sep]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
    Oh, yes there is.

if (CONFIG_FOO) {
....
} else {
....
}
gcc can optimize that away and parser will see the whole thing.

I'm not sure I like this construct either.

Yes, it does mean gcc makes all the decisions and allows the
c-compiler to to more checking (as opposed to the preprocessor which
obviosly is really dumb) but it also assumes the compiler will always
elimiate dead code and I'm not convinced it's any more readable that
have "#if foo" scattered through the code.



--cw
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 12:38    [from the cache]
©2003-2011 Jasper Spaans. Advertise on this site