[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: BFD compile time warning fixes
From: |
Nick Clifton |
Subject: |
Re: BFD compile time warning fixes |
Date: |
22 Sep 2001 08:21:24 +0100 |
User-agent: |
Gnus/5.0808 (Gnus v5.8.8) Emacs/20.7 |
Hi Alan,
> > bfd/elf32-hppa.c: In function `elf32_hppa_check_relocs':
> > bfd/elf32-hppa.c:1588: warning: suggest parentheses around && within ||
> > bfd/elf32-hppa.c: In function `elf32_hppa_relocate_section':
> > bfd/elf32-hppa.c:3936: warning: suggest parentheses around && within ||
>
> These warnings are due to a gcc bug. You get the erroneous warning with
> constructs like the following:
>
> int foo (int a, int b)
> {
> return (a && b && 1) || 0;
> }
I thought that it might be something like that. I considered
reorganising the code to work around the problem, but I do not like
hacking code to get around buggy compilers. Still it would be nice to
have 0 warnings. We could even enable -Werror.... :-)
Cheers
Nick