This situation can occur:
[oota-llvm.git] / lib / Target / TargetMachineRegistry.cpp
index 077b7e8d67b721dcd8f4af6f886b809c267f16a5..62c76bbc5bf14ed2c93e71a7b1ccf1b2880adad1 100644 (file)
@@ -2,8 +2,8 @@
 //
 //                     The LLVM Compiler Infrastructure
 //
-// This file was developed by the LLVM research group and is distributed under
-// the University of Illinois Open Source License. See LICENSE.TXT for details.
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
 //
 //===----------------------------------------------------------------------===//
 //
@@ -32,7 +32,7 @@ const TargetMachineRegistry::entry *
 TargetMachineRegistry::getClosestStaticTargetForModule(const Module &M,
                                                        std::string &Error) {
   std::vector<std::pair<unsigned, const entry *> > UsableTargets;
-  for (iterator I = begin(), E = end(); I != E; ++I)
+  for (Registry<TargetMachine>::iterator I = begin(), E = end(); I != E; ++I)
     if (unsigned Qual = I->ModuleMatchQualityFn(M))
       UsableTargets.push_back(std::make_pair(Qual, &*I));
 
@@ -60,7 +60,7 @@ TargetMachineRegistry::getClosestStaticTargetForModule(const Module &M,
 const TargetMachineRegistry::entry *
 TargetMachineRegistry::getClosestTargetForJIT(std::string &Error) {
   std::vector<std::pair<unsigned, const entry *> > UsableTargets;
-  for (iterator I = begin(), E = end(); I != E; ++I)
+  for (Registry<TargetMachine>::iterator I = begin(), E = end(); I != E; ++I)
     if (unsigned Qual = I->JITMatchQualityFn())
       UsableTargets.push_back(std::make_pair(Qual, &*I));