Re: [PATCH] Fix cpuset sched_relax_domain_level control file

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Adrian Bunk
Date: Wednesday, May 7, 2008 - 2:48 am

On Tue, May 06, 2008 at 06:41:39PM -0700, Paul Menage wrote:

That's very hard to understand for someone who looks at the code - and 
being able to understand the code is much more important than the 
number of characters in the source code.

If you'd write something like

  if ((val < 0) || (val > INT_MAX))

instead it would be obvious for the reader what's happening here, and 
that this was intended.


cu
Adrian

BTW: I have seen that even further restrictions are discussed in this 
     case, my comment is more about the general readability of this
     "simplest approach".

-- 

       "Is there not promise of rain?" Ling Tan asked suddenly out
        of the darkness. There had been need of rain for many days.
       "Only a promise," Lao Er said.
                                       Pearl S. Buck - Dragon Seed

--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
Re: [PATCH] Fix cpuset sched_relax_domain_level control file, Adrian Bunk, (Wed May 7, 2:48 am)