[lkml]   [2005]   [Sep]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    SubjectRe: I request inclusion of reiser4 in the mainline kernel
    Stephen Pollei writes:
    > On 9/18/05, Nikita Danilov <> wrote:
    > > Denis Vlasenko writes:
    > > > On Friday 16 September 2005 20:05, Hans Reiser wrote:
    > > > You can declare functions even if you never use them.
    > > > Thus here you can avoid using #if/#endif:
    > > It's other way around: declaration is guarded by the preprocessor
    > > conditional so that nobody accidentally use znode_is_loaded() outside of
    > > the debugging mode.
    > Except it doesn't disallow someone from using znode_is_loaded, if you
    > wanted to do that you would have done

    I just described why conditionals are used here. You can trust me: I
    wrote that code. :-)

    > #if defined(REISER4_DEBUG) || defined(WHATEVER_ELSE)
    > int znode_is_loaded(const znode * node /* znode to query */ );
    > #else
    > #define znode_is_loaded(I_dont_care_you_are_going_to_) \
    > } )die(]0now[>anyway<}}}}}}*bye*}
    > #endif
    > That way instead of silently(or -Wmissing-prototypes gving a warning)
    > quessing at a prototype and *maybe* geting a link time error, you get
    > a nice compile-time bomb-out.

    Maybe, but kernel developers are supposed to watch for compiler
    messages. People who use that technique definitely do.

    > So unless you have -Wmissing-prototypes and -Werror set then your
    > #if/#endif does very little indeed, especially with the size of kernel
    > it's easy to ignore yet another warning even if the missing-prototype
    > warning was set.

    It's enough to monitor your own code, rather than the whole kernel.

    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: 2005-09-19 23:12    [W:0.019 / U:75.072 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site