diff options
author | Dan Gohman <gohman@apple.com> | 2009-07-31 18:21:48 +0000 |
---|---|---|
committer | Dan Gohman <gohman@apple.com> | 2009-07-31 18:21:48 +0000 |
commit | a818c30d664cd4ba4b9ed69fb2048a6ea55ec9cd (patch) | |
tree | 78382aec42d600063f793c4e9c4c1743f65e4bbd /lib/Analysis/AliasSetTracker.cpp | |
parent | 29384efb76a85e84f87c9bf898262d7f1069c38c (diff) |
Fix some problems with ASTCallbackVH in its use as a DenseMap key.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@77696 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Analysis/AliasSetTracker.cpp')
-rw-r--r-- | lib/Analysis/AliasSetTracker.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/lib/Analysis/AliasSetTracker.cpp b/lib/Analysis/AliasSetTracker.cpp index 9f201c322d..760964c806 100644 --- a/lib/Analysis/AliasSetTracker.cpp +++ b/lib/Analysis/AliasSetTracker.cpp @@ -586,10 +586,12 @@ void AliasSetTracker::ASTCallbackVH::deleted() { } AliasSetTracker::ASTCallbackVH::ASTCallbackVH(Value *V, AliasSetTracker *ast) - : CallbackVH(V == DenseMapInfo<Value *>::getEmptyKey() ? 0 : - V == DenseMapInfo<Value *>::getTombstoneKey() ? 0 : - V), - AST(ast) {} + : CallbackVH(V), AST(ast) {} + +AliasSetTracker::ASTCallbackVH & +AliasSetTracker::ASTCallbackVH::operator=(Value *V) { + return *this = ASTCallbackVH(V, AST); +} //===----------------------------------------------------------------------===// // AliasSetPrinter Pass |