lkml.org 
[lkml]   [2008]   [May]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [RFC] x86: merge nmi_32-64 to nmi.c
Jeremy Fitzhardinge wrote:
> Andi Kleen wrote:
>> The whole idea was pretty bad. Ifdefs are not ugly because the syntax
>> looks ugly, but because it's a semantically ugly construct with bad
>> maintainability impact.
>>
>> Trying to put syntactical sugar around that is a doomed exercise. It
>> will be still ugly, no matter what you do.
>
> Not true. Using C rather than CPP to control the compilation of config
> options has the big win that all code paths are still visible to the
> compiler.

A small win. Still lots of other problems, including testing.

In some cases that's not what you want, but it often is, and
> it would avoid some degree if inadvertent breakage of options. It can
> also be syntactically a lot more pleasant.

Well it's still an unnecessary different code path and making
it look nicer is just an excuse from properly cleaning it up.

-Andi



\
 
 \ /
  Last update: 2008-05-18 21:15    [W:0.050 / U:0.228 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site