]> granicus.if.org Git - clang/commit
[cxx1z-constexpr-lambda] Make a lambda's closure type eligible as a literal-type...
authorFaisal Vali <faisalv@yahoo.com>
Sat, 23 Jul 2016 04:05:19 +0000 (04:05 +0000)
committerFaisal Vali <faisalv@yahoo.com>
Sat, 23 Jul 2016 04:05:19 +0000 (04:05 +0000)
commit816893384b5b496ee70242c3d1cfe2d29e1573d2
treecbd7250958350057c4439c5e137c47b70aa281b8
parent402e84934bdb2b5da17762df1e2a36aded207778
[cxx1z-constexpr-lambda] Make a lambda's closure type eligible as a literal-type in C++1z

Additionally, for pre-C++1z, instead of forbidding a lambda's closure type from being a literal type through circumlocutorily setting HasNonLiteralTypeFieldsOrBases falsely to true -- handle lambda's more directly in CXXRecordDecl::isLiteral().

One additional small step towards implementing constexpr-lambdas.

Thanks to Richard Smith for his review!
https://reviews.llvm.org/D22662

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@276514 91177308-0d34-0410-b5e6-96231b3b80d8
include/clang/AST/DeclCXX.h
test/SemaCXX/cxx1z-constexpr-lambdas.cpp