public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/33558]  New: 'mutable' incorrectly accepted on reference members
@ 2007-09-26  3:13 bangerth at dealii dot org
  2008-12-31 18:02 ` [Bug c++/33558] " pinskia at gcc dot gnu dot org
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: bangerth at dealii dot org @ 2007-09-26  3:13 UTC (permalink / raw)
  To: gcc-bugs

7.1.1/8 says that 'mutable' can't be applied to reference members:
  The mutable specifier can be applied only to names  of
  class  data  members  (_class.mem_)  and  cannot  be  applied to names
  declared const or static, and cannot be applied to reference  members.

Yet gcc accepts this code:
----------------
class X {
    mutable int &q;
};
----------------
This would seem to be in error.

W.


-- 
           Summary: 'mutable' incorrectly accepted on reference members
           Product: gcc
           Version: 4.1.2
            Status: UNCONFIRMED
          Keywords: accepts-invalid
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: bangerth at dealii dot org


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


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

end of thread, other threads:[~2010-01-09 14:19 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-09-26  3:13 [Bug c++/33558] New: 'mutable' incorrectly accepted on reference members bangerth at dealii dot org
2008-12-31 18:02 ` [Bug c++/33558] " pinskia at gcc dot gnu dot org
2010-01-09 14:18 ` gafunchal at gmail dot com
2010-01-09 14:19 ` gafunchal at gmail 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).