massberg created this revision. massberg added a reviewer: ilya-biryukov. Herald added a project: All. massberg requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits.
Rename parameter in Sema::addInitCapture as proposed in review of Sema::addInitCapture. Sorry, that I have missed the comment there! Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D139541 Files: clang/include/clang/Sema/Sema.h clang/lib/Sema/SemaLambda.cpp Index: clang/lib/Sema/SemaLambda.cpp =================================================================== --- clang/lib/Sema/SemaLambda.cpp +++ clang/lib/Sema/SemaLambda.cpp @@ -887,10 +887,9 @@ return NewVD; } -void Sema::addInitCapture(LambdaScopeInfo *LSI, VarDecl *Var, - bool isReferenceType) { +void Sema::addInitCapture(LambdaScopeInfo *LSI, VarDecl *Var, bool ByRef) { assert(Var->isInitCapture() && "init capture flag should be set"); - LSI->addCapture(Var, /*isBlock*/ false, isReferenceType, + LSI->addCapture(Var, /*isBlock*/ false, ByRef, /*isNested*/ false, Var->getLocation(), SourceLocation(), Var->getType(), /*Invalid*/ false); } Index: clang/include/clang/Sema/Sema.h =================================================================== --- clang/include/clang/Sema/Sema.h +++ clang/include/clang/Sema/Sema.h @@ -7097,8 +7097,7 @@ unsigned InitStyle, Expr *Init); /// Add an init-capture to a lambda scope. - void addInitCapture(sema::LambdaScopeInfo *LSI, VarDecl *Var, - bool isReferenceType); + void addInitCapture(sema::LambdaScopeInfo *LSI, VarDecl *Var, bool ByRef); /// Note that we have finished the explicit captures for the /// given lambda.
Index: clang/lib/Sema/SemaLambda.cpp =================================================================== --- clang/lib/Sema/SemaLambda.cpp +++ clang/lib/Sema/SemaLambda.cpp @@ -887,10 +887,9 @@ return NewVD; } -void Sema::addInitCapture(LambdaScopeInfo *LSI, VarDecl *Var, - bool isReferenceType) { +void Sema::addInitCapture(LambdaScopeInfo *LSI, VarDecl *Var, bool ByRef) { assert(Var->isInitCapture() && "init capture flag should be set"); - LSI->addCapture(Var, /*isBlock*/ false, isReferenceType, + LSI->addCapture(Var, /*isBlock*/ false, ByRef, /*isNested*/ false, Var->getLocation(), SourceLocation(), Var->getType(), /*Invalid*/ false); } Index: clang/include/clang/Sema/Sema.h =================================================================== --- clang/include/clang/Sema/Sema.h +++ clang/include/clang/Sema/Sema.h @@ -7097,8 +7097,7 @@ unsigned InitStyle, Expr *Init); /// Add an init-capture to a lambda scope. - void addInitCapture(sema::LambdaScopeInfo *LSI, VarDecl *Var, - bool isReferenceType); + void addInitCapture(sema::LambdaScopeInfo *LSI, VarDecl *Var, bool ByRef); /// Note that we have finished the explicit captures for the /// given lambda.
_______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits