public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/24983]  New: Needs a warning?
@ 2005-11-22  2:31 igodard at pacbell dot net
  2005-11-22  2:46 ` [Bug c++/24983] " gdr at integrable-solutions dot net
                   ` (6 more replies)
  0 siblings, 7 replies; 9+ messages in thread
From: igodard at pacbell dot net @ 2005-11-22  2:31 UTC (permalink / raw)
  To: gcc-bugs

struct foo { const void f(); };
void foo::f(){}

gets you:

~/ootbc/members/src$ g++ foo.cc -Wall
foo.cc:2: error: prototype for `void foo::f()' does not match any in class
`foo'
foo.cc:1: error: candidate is: const void foo::f()
foo.cc:2: error: `void foo::f()' and `const void foo::f()' cannot be overloaded

Comeau gives a warning on the declaration and one error (not two) on the
definition.


-- 
           Summary: Needs a warning?
           Product: gcc
           Version: 3.4.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: igodard at pacbell dot net


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24983


^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2008-03-30 20:45 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-11-22  2:31 [Bug c++/24983] New: Needs a warning? igodard at pacbell dot net
2005-11-22  2:46 ` [Bug c++/24983] " gdr at integrable-solutions dot net
2005-11-22  3:01 ` pinskia at gcc dot gnu dot org
2005-11-22  3:58   ` Gabriel Dos Reis
2005-11-22  3:45 ` igodard at pacbell dot net
2005-11-22  3:58 ` gdr at integrable-solutions dot net
2005-11-22  4:05 ` igodard at pacbell dot net
2005-11-23  5:25 ` bangerth at dealii dot org
2008-03-30 20:45 ` pinskia at gcc dot gnu dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).