[lkml]   [2004]   [Mar]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: Linux 2.4.26-pre2
On Sun, 7 Mar 2004 21:05:09 +0100, David Weinehall <> wrote:

> On Sun, Mar 07, 2004 at 08:52:45PM +0100, Rene Herman wrote:
>> David Weinehall wrote:
>> >>>In standard C we declare all variables at the top of a function. While
>> >>>some compilers allow extension, it is not a good idea to get used to
>> >>>them if we want portable code.
>> >>
>> >>Oh, come on. This is _kernel_ code, it won't ever be compiled with
>> >>anything
>> >>not GCC-compatible.
>> >
>> >Ugly warts don't become any less ugly just because gcc accepts them...
>> Mixing code and declarations is also c99. For (a sane) gcc specifically,
>> you have to tell it -std=c89 -pedantic to have it even complain.
> Ok, didn't know that. Still doesn't make it any less ugly, though.
> There are quite a lot of things that a valid in C. That doesn't mean
> they should be used...

C99 is C++ish. I have my experience with these methods after following
the PopularCppWays for some time. HellIsThisCrap which I wrote a pain
to maintain...

When a function is short and concise, there is no need to worry about
the few variables at the top.


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-03-22 14:01    [W:0.060 / U:0.852 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site