public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/57820] New: Can't initialize a constexpr object with inline initialization
@ 2013-07-04  9:45 liweifriends at gmail dot com
  2013-07-04  9:57 ` [Bug c++/57820] " redi at gcc dot gnu.org
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: liweifriends at gmail dot com @ 2013-07-04  9:45 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 57820
           Summary: Can't initialize a constexpr object with inline
                    initialization
           Product: gcc
           Version: 4.8.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: liweifriends at gmail dot com

the source code:

struct C
{
    int a = 2;
    int b = a + 1;
};

C c;  //OK
constexpr C d; //error

int main()
{
}

Why I can't initialize d?


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

end of thread, other threads:[~2024-04-04  0:21 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-07-04  9:45 [Bug c++/57820] New: Can't initialize a constexpr object with inline initialization liweifriends at gmail dot com
2013-07-04  9:57 ` [Bug c++/57820] " redi at gcc dot gnu.org
2013-07-04 17:46 ` harald at gigawatt dot nl
2014-11-03 10:40 ` paolo.carlini at oracle dot com
2014-11-03 10:49 ` paolo at gcc dot gnu.org
2014-11-20 12:57 ` [Bug c++/57820] [DR 253] NSDMI and const objects jason at gcc dot gnu.org
2024-04-04  0:21 ` pinskia at gcc dot gnu.org

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