This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/45923] constexpr diagnostic w/ non-literal
- From: "jason at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Thu, 7 Oct 2010 15:35:49 +0000
- Subject: [Bug c++/45923] constexpr diagnostic w/ non-literal
- Auto-submitted: auto-generated
- References: <bug-45923-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45923
--- Comment #1 from Jason Merrill <jason at gcc dot gnu.org> 2010-10-07 15:35:45 UTC ---
(In reply to comment #0)
> constexpr-basic.cc:20:33: error: âdouble complex::real() constâ is not a
> constexpr function
>
> NO!
Yes. It is not valid for real() to be constexpr in a non-literal class, so it
is not constexpr.