Consilidate SmallPtrSet count() followed by insert() into a single insert().

llvm-svn: 162330
This commit is contained in:
Ted Kremenek 2012-08-22 00:02:08 +00:00
parent 7fb0cd26f7
commit 34d39287b5
1 changed files with 2 additions and 6 deletions

View File

@ -477,12 +477,8 @@ public:
}
bool AddToWorkList(const MemRegion *R, const ClusterBindings *C) {
if (C) {
if (Visited.count(C))
return false;
Visited.insert(C);
}
if (C && !Visited.insert(C))
return false;
WL.push_back(R);
return true;
}