diff options
author | Rafael Espindola <rafael.espindola@gmail.com> | 2014-05-16 20:05:08 +0000 |
---|---|---|
committer | Rafael Espindola <rafael.espindola@gmail.com> | 2014-05-16 20:05:08 +0000 |
commit | 0bf5b143f515ebbccc0d6a3ab8d1ffca3631ee73 (patch) | |
tree | 10e1e681eda35012615c5da60561501778a56e81 /llvm/lib | |
parent | ec47b2217e4a8d929eb4b2375623f79caf119dee (diff) | |
download | bcm5719-llvm-0bf5b143f515ebbccc0d6a3ab8d1ffca3631ee73.tar.gz bcm5719-llvm-0bf5b143f515ebbccc0d6a3ab8d1ffca3631ee73.zip |
Fix a warning in builds without asserts.
llvm-svn: 209012
Diffstat (limited to 'llvm/lib')
-rw-r--r-- | llvm/lib/IR/Value.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/llvm/lib/IR/Value.cpp b/llvm/lib/IR/Value.cpp index a3c02862007..d734e4ea818 100644 --- a/llvm/lib/IR/Value.cpp +++ b/llvm/lib/IR/Value.cpp @@ -317,8 +317,7 @@ static GlobalObject &findReplacementForAliasUse(Value &C) { static void replaceAliasUseWith(Use &U, Value *New) { GlobalObject &Replacement = findReplacementForAliasUse(*New); - auto *Old = &cast<GlobalObject>(*U); - assert(Old != &Replacement && + assert(&cast<GlobalObject>(*U) != &Replacement && "replaceAliasUseWith cannot form an alias cycle"); U.set(&Replacement); } |