From f3c1335c596e2a45a877e39a139b23ea5481eb37 Mon Sep 17 00:00:00 2001 From: Michael Gottesman Date: Mon, 14 Jan 2013 19:18:39 +0000 Subject: [PATCH] Changed SmallPtrSet.count guard + SmallPtrSet.insert to just SmallPtrSet.insert. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172452 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Transforms/Scalar/ObjCARC.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/lib/Transforms/Scalar/ObjCARC.cpp b/lib/Transforms/Scalar/ObjCARC.cpp index e7c51780411..abd6b4185f6 100644 --- a/lib/Transforms/Scalar/ObjCARC.cpp +++ b/lib/Transforms/Scalar/ObjCARC.cpp @@ -662,10 +662,9 @@ static bool DoesObjCBlockEscape(const Value *BlockPtr) { if (isa(UUser) || isa(UUser) || isa(UUser) || isa(UUser)) { - if (!VisitedSet.count(UUser)) { + if (!VisitedSet.insert(UUser)) { DEBUG(dbgs() << "DoesObjCBlockEscape: User copies value. Escapes " "if result escapes. Adding to list.\n"); - VisitedSet.insert(V); Worklist.push_back(UUser); } else { DEBUG(dbgs() << "DoesObjCBlockEscape: Already visited node.\n"); -- 2.34.1