diff options
Diffstat (limited to 'clang/lib/CodeGen/CodeGenFunction.h')
-rw-r--r-- | clang/lib/CodeGen/CodeGenFunction.h | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/clang/lib/CodeGen/CodeGenFunction.h b/clang/lib/CodeGen/CodeGenFunction.h index 54289cdd6de..6ea2d75b318 100644 --- a/clang/lib/CodeGen/CodeGenFunction.h +++ b/clang/lib/CodeGen/CodeGenFunction.h @@ -1787,7 +1787,7 @@ public: llvm::Value *ptr); Address LoadBlockStruct(); - Address GetAddrOfBlockDecl(const VarDecl *var); + Address GetAddrOfBlockDecl(const VarDecl *var, bool ByRef); /// BuildBlockByrefAddress - Computes the location of the /// data in a variable which is declared as __block. @@ -2683,9 +2683,8 @@ public: llvm::Value *NRVOFlag; - /// True if the variable is a __block variable that is captured by an - /// escaping block. - bool IsEscapingByRef; + /// True if the variable is a __block variable. + bool IsByRef; /// True if the variable is of aggregate type and has a constant /// initializer. @@ -2705,7 +2704,7 @@ public: AutoVarEmission(const VarDecl &variable) : Variable(&variable), Addr(Address::invalid()), NRVOFlag(nullptr), - IsEscapingByRef(false), IsConstantAggregate(false), + IsByRef(false), IsConstantAggregate(false), SizeForLifetimeMarkers(nullptr), AllocaAddr(Address::invalid()) {} bool wasEmittedAsGlobal() const { return !Addr.isValid(); } @@ -2735,7 +2734,7 @@ public: /// Note that this does not chase the forwarding pointer for /// __block decls. Address getObjectAddress(CodeGenFunction &CGF) const { - if (!IsEscapingByRef) return Addr; + if (!IsByRef) return Addr; return CGF.emitBlockByrefAddress(Addr, Variable, /*forward*/ false); } |