[lkml]   [2006]   [Aug]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    SubjectRe: Conversion to generic boolean
    Jan Engelhardt wrote:

    >>>Just would like to ask if you want patches for:
    >>Total NACK to any of this boolean ididocy. I very much hope you didn't
    >>get the impression you actually have a chance to get this merged.
    >>>* (Most importent, may introduce bugs if left alone)
    >>>Fixing boolean checking, ex:
    >>>if (bool == FALSE)
    >>>if (!bool)
    >>this one of course makes sense, but please do it without introducing
    >>any boolean type. Getting rid of all the TRUE/FALSE defines and converting
    >>all scsi drivers to classic C integer as boolean semantics would be
    >>very welcome janitorial work.
    >I don't get it. You object to the 'idiocy'
    >(, but find the x==FALSE -> !x
    >a good thing?
    That is error-prone. Not "==FALSE" but what happens if x is (for some
    reason) not 1 and then "if (x==TRUE)". There has been suggestions of doing:
    if (x != FALSE)
    if (!x == !TRUE)
    but a simple "if (x)" is (in my opinion) the correct way.

    Then that there is some objections booleans not being the "classical
    C"-way, is another story.

    >Jan Engelhardt
    Richard Knutsson
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to
    More majordomo info at
    Please read the FAQ at

     \ /
      Last update: 2006-08-28 14:13    [W:0.020 / U:7.592 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site