]> granicus.if.org Git - clang/commit
First pass of semantic analysis for init-captures: check the initializer, build
authorRichard Smith <richard-llvm@metafoo.co.uk>
Thu, 16 May 2013 06:20:58 +0000 (06:20 +0000)
committerRichard Smith <richard-llvm@metafoo.co.uk>
Thu, 16 May 2013 06:20:58 +0000 (06:20 +0000)
commit0d8e9646bc000bab521ce52ed294209a92298cef
treee3fad0a3fa5871bc33949aef92a0b892656ef405
parentc45c8dd54bc54f9be46546fdf002dc9fe07d1715
First pass of semantic analysis for init-captures: check the initializer, build
a FieldDecl from it, and propagate both into the closure type and the
LambdaExpr.

You can't do much useful with them yet -- you can't use them within the body
of the lambda, because we don't have a representation for "the this of the
lambda, not the this of the enclosing context". We also don't have support or a
representation for a nested capture of an init-capture yet, which was intended
to work despite not being allowed by the current standard wording.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@181985 91177308-0d34-0410-b5e6-96231b3b80d8
28 files changed:
include/clang/AST/DeclCXX.h
include/clang/AST/ExprCXX.h
include/clang/AST/RecursiveASTVisitor.h
include/clang/Basic/DiagnosticSemaKinds.td
include/clang/Basic/Lambda.h
include/clang/Sema/ScopeInfo.h
include/clang/Sema/Sema.h
lib/AST/DeclCXX.cpp
lib/AST/ExprCXX.cpp
lib/AST/Stmt.cpp
lib/AST/StmtPrinter.cpp
lib/AST/StmtProfile.cpp
lib/Parse/ParseExprCXX.cpp
lib/Sema/SemaExpr.cpp
lib/Sema/SemaLambda.cpp
lib/Sema/SemaStmt.cpp
lib/Sema/SemaTemplateVariadic.cpp
lib/Sema/TreeTransform.h
lib/Serialization/ASTReaderDecl.cpp
lib/Serialization/ASTWriter.cpp
test/CXX/expr/expr.prim/expr.prim.lambda/p11-1y.cpp [new file with mode: 0644]
test/CXX/expr/expr.prim/expr.prim.lambda/p23.cpp
test/CXX/expr/expr.prim/expr.prim.lambda/p8.cpp
test/PCH/cxx11-lambdas.mm
test/Parser/cxx0x-lambda-expressions.cpp
test/Parser/objcxx0x-lambda-expressions.mm
tools/libclang/CIndex.cpp
tools/libclang/IndexBody.cpp