[C++11] Add range based accessors for the Use-Def chain of a Value.
[oota-llvm.git] / lib / IR / AutoUpgrade.cpp
index ca441433077f2af9d2126d7c53cb9b9f0aeac077..b7429b30f5a1af97876a079e502037f33bbf1652 100644 (file)
@@ -411,7 +411,7 @@ void llvm::UpgradeCallsToIntrinsic(Function* F) {
   if (UpgradeIntrinsicFunction(F, NewFn)) {
     if (NewFn != F) {
       // Replace all uses to the old function with the new one if necessary.
-      for (Value::use_iterator UI = F->use_begin(), UE = F->use_end();
+      for (Value::user_iterator UI = F->user_begin(), UE = F->user_end();
            UI != UE; ) {
         if (CallInst *CI = dyn_cast<CallInst>(*UI++))
           UpgradeIntrinsicCall(CI, NewFn);