From 44baa8abba2a1552b6b50bf750a8750ab9da9f76 Mon Sep 17 00:00:00 2001 From: Fariborz Jahanian Date: Sun, 22 Feb 2009 18:40:18 +0000 Subject: More objc gc work. Match gcc's treatment of ivar access true a local pointer to objective-c object in generating write barriers. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65290 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/CodeGen/CGExpr.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/CodeGen/CGExpr.cpp') diff --git a/lib/CodeGen/CGExpr.cpp b/lib/CodeGen/CGExpr.cpp index 2348a11f7b..c96265242a 100644 --- a/lib/CodeGen/CGExpr.cpp +++ b/lib/CodeGen/CGExpr.cpp @@ -782,7 +782,7 @@ LValue CodeGenFunction::EmitArraySubscriptExpr(const ArraySubscriptExpr *E) { getContext().getObjCGCAttrKind(T)); if (getContext().getLangOptions().ObjC1 && getContext().getLangOptions().getGCMode() != LangOptions::NonGC) - LValue::SetObjCNonGC(LV, !E->hasGlobalStorage()); + LValue::SetObjCNonGC(LV, !E->isOBJCGCCandidate()); return LV; } -- cgit v1.2.3