lkml.org 
[lkml]   [2006]   [Feb]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] Provide an interface for getting the current tick length


On Thu, 16 Feb 2006, Paul Mackerras wrote:
>
> We could share the code that computes time_adjust_step, i.e. this
> much:
>
> if ((time_adjust_step = time_adjust) != 0) {

And while at it, please make it much more readable by writing it as

time_adjust_step = time_adjust;
if (time_adjust_step) {
..
which is even less to type (no "!= 0", no extra parenthesis, just a
";<nl><tab>", and you've saved a whopping three bytes of source code while
making the end result more readable, and the compiler will generate the
same thing.

Assignments inside tests should probably be relegated entirely to loop
constructs, where doing them outside the test changes semantics.

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

\
 
 \ /
  Last update: 2009-11-18 23:46    [from the cache]
©2003-2011 Jasper Spaans