This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/24983] Needs a warning?



------- Comment #3 from igodard at pacbell dot net  2005-11-22 03:45 -------
The 3.0 is the best error, but I like the warning that comeau also gives:

Comeau C/C++ 4.3.3 (Aug  6 2003 15:13:37) for ONLINE_EVALUATION_BETA1
Copyright 1988-2003 Comeau Computing.  All rights reserved.
MODE:strict errors C++

"ComeauTest.c", line 1: warning: type qualifier on return type is meaningless
  struct foo { const void f(); };
                          ^

"ComeauTest.c", line 2: error: declaration is incompatible with
          "const void foo::f()" (declared at line 1)
  void foo::f(){}
            ^

1 error detected in the compilation of "ComeauTest.c".


-- 


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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]