This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/34811] Classes without attributes declared as const need initializer.
- From: "rguenth at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 16 Jan 2008 13:32:44 -0000
- Subject: [Bug c++/34811] Classes without attributes declared as const need initializer.
- References: <bug-34811-15648@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #1 from rguenth at gcc dot gnu dot org 2008-01-16 13:32 -------
EDG says:
t.C(27): error: const variable "sM" requires an initializer -- class
"signalManager" has no explicitly declared default constructor
} const sM ;
^
compilation aborted for t.C (code 2)
which is correct. Try
} const sM = signalManager();
--
rguenth at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Resolution| |INVALID
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34811