Avoid dispose calls when only doing gc.

llvm-svn: 66126
This commit is contained in:
Mike Stump 2009-03-05 02:34:38 +00:00
parent 6c29a91c05
commit cd1280b405
1 changed files with 1 additions and 1 deletions

View File

@ -391,7 +391,7 @@ void CodeGenFunction::EmitLocalBlockVarDecl(const VarDecl &D) {
EmitCall(CGM.getTypes().getFunctionInfo(FD), F, Args);
}
if (needsDispose) {
if (needsDispose && CGM.getLangOptions().getGCMode() != LangOptions::GCOnly) {
CleanupScope scope(*this);
BuildBlockRelease(D, DeclPtr);
}