Source-Changes-D archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: CVS commit: src/lib/libc/stdio



On 28 March 2012 07:53, Christos Zoulas <christos%astron.com@localhost> wrote:
> In article <20120327202907.GT26108%bigmac.stderr.spb.ru@localhost>,
> Valeriy E. Ushakov <uwe%stderr.spb.ru@localhost> wrote:
>>
>>But that is not what the code was.  The code was:
>>
>>    char c; if (c == CHAR_MAX) ...
>>
>>and *that* is portable.  As I said in another mail to thsi thread that
>>went unanswered, it is literally schizophrenic of lint to complain
>>about it.
>
> How can lint know that if (c == 255) is portable? Because CHAR_MAX
> gets expanded by cpp to 255 before lint parses the file.
>

(How) does the compiler (not) catch this one ?

-- 
~Cherry


Home | Main Index | Thread Index | Old Index