diff options
author | Peter Collingbourne <peter@pcc.me.uk> | 2012-01-26 03:33:36 +0000 |
---|---|---|
committer | Peter Collingbourne <peter@pcc.me.uk> | 2012-01-26 03:33:36 +0000 |
commit | 516bbd42e62d709013824d6fb8445a0cfda3129a (patch) | |
tree | 1a44b96f7cf895fd81aa2737a3c732bc3498d903 /lib/CodeGen/CGBlocks.cpp | |
parent | 24466d8a90a5c097d7cc505bd0a2433f0835dc73 (diff) |
Use function pointers, rather than references, to pass Destroyers
around, in the process cleaning up the various gcc/msvc compiler
workarounds.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@149036 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGBlocks.cpp')
-rw-r--r-- | lib/CodeGen/CGBlocks.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/CodeGen/CGBlocks.cpp b/lib/CodeGen/CGBlocks.cpp index e6ecb6a88b..c6d5be059c 100644 --- a/lib/CodeGen/CGBlocks.cpp +++ b/lib/CodeGen/CGBlocks.cpp @@ -535,9 +535,9 @@ static void enterBlockScope(CodeGenFunction &CGF, BlockDecl *block) { // Block captures count as local values and have imprecise semantics. // They also can't be arrays, so need to worry about that. if (dtorKind == QualType::DK_objc_strong_lifetime) { - destroyer = &CodeGenFunction::destroyARCStrongImprecise; + destroyer = CodeGenFunction::destroyARCStrongImprecise; } else { - destroyer = &CGF.getDestroyer(dtorKind); + destroyer = CGF.getDestroyer(dtorKind); } // GEP down to the address. @@ -554,7 +554,7 @@ static void enterBlockScope(CodeGenFunction &CGF, BlockDecl *block) { cleanupKind = InactiveNormalAndEHCleanup; CGF.pushDestroy(cleanupKind, addr, variable->getType(), - *destroyer, useArrayEHCleanup); + destroyer, useArrayEHCleanup); // Remember where that cleanup was. capture.setCleanup(CGF.EHStack.stable_begin()); |