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 Tue, Mar 27, 2012 at 20:19:41 +0000, Christos Zoulas wrote:
> In article
> <CAN6pqGQMV-JtfuidyRAH1VoYV7mJott=ARUq3T3nro1KWCD2ug%mail.gmail.com@localhost>,
> Takehiko NOZAKI <takehiko.nozaki%gmail.com@localhost> wrote:
> >-=-=-=-=-=-
> >
> >Hi,
> >
> >It seems that lint(1) is not cross build safe, it doesn't handle MD char
> >default type of sign/unsignd. See src/usr.bin/xlint/lint1/tree.c::cvtcon().
> >They use host MD CHAR_MAX directry ;)
> >
> >So, if cross building ppc/arm on other arch cause false alarm , "out of
> >range " warnng.
>
> It is not out of range warning, it is:
>
> "nonportable character comparison, op %s", /* 230 */
>
> the question is if 'char c; if (c == 255)' is portable or not.
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.
I used to be on the fence about lint, leaning more towards favorable
side. But recent rounds of lint induced churn made me change my mind.
-uwe
Home |
Main Index |
Thread Index |
Old Index