Georg-Johann Lay writes:
> Richard Sandiford schrieb:
>> I've been working on some patches to make insn_rtx_cost take account
>> of the cost of SET_DESTs as well as SET_SRCs. But I'm slowly beginning
>> to realise that I don't understand what rtx costs are supposed to represent.
>>
>> AIUI the r
Hans-Peter Nilsson writes:
>> But that hardly seems clean either. Perhaps we should instead make
>> the SET_SRC always include the cost of the SET, even for registers,
>> constants and the like. Thoughts?
>
> Seems more of maintaining a wart than an improvement for
> consistency.
So, to enumera
Since -Wmissing-prototypes doesn't work for C++, using
C++ to bootstrap GCC makes -Wmissing-prototypes useless.
You will see the -Wmissing-prototypes message in stage 1,
but you won't see it in stage3 2/3.
--
H.J.
I'm confused. Since C++ treats the lack of a prototype as a hard error, what
does it mean to make -Wmissing-prototypes useless?
From: gcc-ow...@gcc.gnu.org [gcc-ow...@gcc.gnu.org] On Behalf Of H.J. Lu
[hjl.to...@gmail.com]
Sent: Friday, August 19, 2011 9:
[hjl@gnu-33 gcc]$ cat x.c
int
foo (int x)
{
return x;
}
[hjl@gnu-33 gcc]$ ./xgcc -B./ -S -O -Wmissing-prototypes x.c
x.c:2:1: warning: no previous prototype for ‘foo’ [-Wmissing-prototypes]
[hjl@gnu-33 gcc]$ ./g++ -B./ -S -O -Wmissing-prototypes x.c
cc1plus: warning: command line option ‘-Wmissin
I think the point is that the effect of -Wmissing-prototypes is always enabled
in C++, so that switch is rejected. The solution would seem to be to remove
that switch from the command line if C++ is used to build; that will produce
the intended result.
paul
-Original Message-
On Fri, Aug 19, 2011 at 1:35 PM, wrote:
> I think the point is that the effect of -Wmissing-prototypes is always
> enabled in C++, so that switch is rejected. The solution would seem to be to
> remove that switch from the command line if C++ is used to build; that will
> produce the intended
"H.J. Lu" writes:
> [hjl@gnu-33 gcc]$ cat x.c
> int
> foo (int x)
> {
> return x;
> }
> [hjl@gnu-33 gcc]$ ./xgcc -B./ -S -O -Wmissing-prototypes x.c
> x.c:2:1: warning: no previous prototype for ‘foo’ [-Wmissing-prototypes]
> [hjl@gnu-33 gcc]$ ./g++ -B./ -S -O -Wmissing-prototypes x.c
> cc1plus
On Fri, 19 Aug 2011, Joe Buck wrote:
I'm confused. Since C++ treats the lack of a prototype as a hard error,
what does it mean to make -Wmissing-prototypes useless?
-Wmissing-prototype looks very similar to -Wmissing-declarations (which is
supported in C++ but documented as C/objC only). It r
On Fri, Aug 19, 2011 at 2:45 PM, Ian Lance Taylor wrote:
> "H.J. Lu" writes:
>
>> [hjl@gnu-33 gcc]$ cat x.c
>> int
>> foo (int x)
>> {
>> return x;
>> }
>> [hjl@gnu-33 gcc]$ ./xgcc -B./ -S -O -Wmissing-prototypes x.c
>> x.c:2:1: warning: no previous prototype for ‘foo’ [-Wmissing-prototypes]
>>
Snapshot gcc-4.6-20110819 is now available on
ftp://gcc.gnu.org/pub/gcc/snapshots/4.6-20110819/
and on various mirrors, see http://gcc.gnu.org/mirrors.html for details.
This snapshot has been generated from the GCC 4.6 SVN branch
with the following options: svn://gcc.gnu.org/svn/gcc/branches
On Fri, Aug 19, 2011 at 4:45 PM, Ian Lance Taylor wrote:
> "H.J. Lu" writes:
>
>> [hjl@gnu-33 gcc]$ cat x.c
>> int
>> foo (int x)
>> {
>> return x;
>> }
>> [hjl@gnu-33 gcc]$ ./xgcc -B./ -S -O -Wmissing-prototypes x.c
>> x.c:2:1: warning: no previous prototype for ‘foo’ [-Wmissing-prototypes]
>>
Gabriel Dos Reis writes:
> what would it do? There is no notion of `prototype' in C++ (as C
> programmers understand it).
> So, what would it mean to warn about something we can't take the
> negation of? ;-)
-Wmissing-prototypes means that if the compiler sees a globally visible
function defini
On Fri, Aug 19, 2011 at 11:17 PM, Ian Lance Taylor wrote:
> Gabriel Dos Reis writes:
>
>> what would it do? There is no notion of `prototype' in C++ (as C
>> programmers understand it).
>> So, what would it mean to warn about something we can't take the
>> negation of? ;-)
>
> -Wmissing-prototyp
14 matches
Mail list logo