]> granicus.if.org Git - clang/commit
A union can have a constexpr defaulted default constructor, if it has an
authorRichard Smith <richard-llvm@metafoo.co.uk>
Mon, 7 May 2012 01:07:30 +0000 (01:07 +0000)
committerRichard Smith <richard-llvm@metafoo.co.uk>
Mon, 7 May 2012 01:07:30 +0000 (01:07 +0000)
commitd079abfb5eefaf7da232e39a6564f561402cf4fe
treee63d342c8c400c0b7a35eb50620c6348cbb75e81
parent3127d48cd8572d88d16e2b2d16045bdb3f7a4a98
A union can have a constexpr defaulted default constructor, if it has an
in-class initializer for one of its fields. Value-initialization of such
a type should use the in-class initializer!

The former was just a bug, the latter is a (reported) standard defect.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@156274 91177308-0d34-0410-b5e6-96231b3b80d8
include/clang/AST/DeclCXX.h
lib/AST/ASTImporter.cpp
lib/AST/DeclCXX.cpp
lib/Sema/SemaInit.cpp
lib/Serialization/ASTReaderDecl.cpp
lib/Serialization/ASTWriter.cpp
test/CXX/special/class.ctor/p6-0x.cpp
test/CodeGenCXX/const-init-cxx11.cpp
test/CodeGenCXX/member-init-anon-union.cpp