diff options
author | Ted Kremenek <kremenek@apple.com> | 2008-03-09 18:32:50 +0000 |
---|---|---|
committer | Ted Kremenek <kremenek@apple.com> | 2008-03-09 18:32:50 +0000 |
commit | d48ed17d182db89c86fc9911211234e1e2e6ae09 (patch) | |
tree | 72970f8afed878d52f79ed87e37f797701b7b2ab /llvm | |
parent | 6c504797375628134a0d9868b53a8146ab0e879a (diff) | |
download | bcm5719-llvm-d48ed17d182db89c86fc9911211234e1e2e6ae09.tar.gz bcm5719-llvm-d48ed17d182db89c86fc9911211234e1e2e6ae09.zip |
Fix some compilation errors on msvc:
- "Redefinition of I" (iterator masks previous definition)
- include missing header file
Patch by Argiris Kirtzidis!
llvm-svn: 48115
Diffstat (limited to 'llvm')
-rw-r--r-- | llvm/lib/Linker/LinkModules.cpp | 6 | ||||
-rw-r--r-- | llvm/lib/Transforms/IPO/ExtractGV.cpp | 1 |
2 files changed, 4 insertions, 3 deletions
diff --git a/llvm/lib/Linker/LinkModules.cpp b/llvm/lib/Linker/LinkModules.cpp index 5545af69f16..ad6852dce6a 100644 --- a/llvm/lib/Linker/LinkModules.cpp +++ b/llvm/lib/Linker/LinkModules.cpp @@ -597,9 +597,9 @@ static bool LinkAlias(Module *Dest, const Module *Src, // Globals were already linked, thus we can just query ValueMap for variant // of SAliasee in Dest - std::map<const Value*,Value*>::const_iterator I = ValueMap.find(SAliasee); - assert(I != ValueMap.end() && "Aliasee not linked"); - GlobalValue* DAliasee = cast<GlobalValue>(I->second); + std::map<const Value*,Value*>::const_iterator VMI = ValueMap.find(SAliasee); + assert(VMI != ValueMap.end() && "Aliasee not linked"); + GlobalValue* DAliasee = cast<GlobalValue>(VMI->second); // Try to find something 'similar' to SGA in destination module. if (GlobalAlias *DGA = Dest->getNamedAlias(SGA->getName())) { diff --git a/llvm/lib/Transforms/IPO/ExtractGV.cpp b/llvm/lib/Transforms/IPO/ExtractGV.cpp index a230dd1db88..882097cae55 100644 --- a/llvm/lib/Transforms/IPO/ExtractGV.cpp +++ b/llvm/lib/Transforms/IPO/ExtractGV.cpp @@ -17,6 +17,7 @@ #include "llvm/Constants.h" #include "llvm/Transforms/IPO.h" #include "llvm/Support/Compiler.h" +#include <algorithm> using namespace llvm; namespace { |