public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/13452] New: No error on invalid (I think) C++ code
@ 2003-12-19 19:28 ian at airs dot com
  2003-12-23 18:33 ` [Bug c++/13452] " pinskia at gcc dot gnu dot org
                   ` (3 more replies)
  0 siblings, 4 replies; 7+ messages in thread
From: ian at airs dot com @ 2003-12-19 19:28 UTC (permalink / raw)
  To: gcc-bugs

This code is compiled without error in the current mainline:

class C { public: template<typename i> int (*f())() const; };

However, it now seems to me that there should be an error on the trailing const.
 Otherwise, I have no idea what the trailing const means.  It appears that
generating a const method (i.e., a method for which `this' is a pointer to
const) requires

class C { public: template<typename i> int (*f() const)(); };

This may be a misunderstanding on my part, but at least some people share my
misunderstanding; see PR c++/13447.

-- 
           Summary: No error on invalid (I think) C++ code
           Product: gcc
           Version: 3.4.0
            Status: UNCONFIRMED
          Severity: minor
          Priority: P2
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: ian at airs dot com
                CC: gcc-bugs at gcc dot gnu dot org
 GCC build triplet: i686-pc-linux-gnu
  GCC host triplet: i686-pc-linux-gnu
GCC target triplet: i686-pc-linux-gnu


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


^ permalink raw reply	[flat|nested] 7+ messages in thread
[parent not found: <bug-13452-4@http.gcc.gnu.org/bugzilla/>]

end of thread, other threads:[~2013-06-16 16:14 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-12-19 19:28 [Bug c++/13452] New: No error on invalid (I think) C++ code ian at airs dot com
2003-12-23 18:33 ` [Bug c++/13452] " pinskia at gcc dot gnu dot org
2004-01-12 16:11 ` Rainer dot Bensch at rsd dot rohde-schwarz dot com
2004-01-12 16:27 ` ian at airs dot com
2005-05-25  1:11 ` ian at airs dot com
     [not found] <bug-13452-4@http.gcc.gnu.org/bugzilla/>
2013-04-09 17:16 ` paolo.carlini at oracle dot com
2013-06-16 16:14 ` paolo.carlini at oracle dot com

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).