diff options
author | Rafael Espindola <rafael.espindola@gmail.com> | 2013-05-04 03:48:37 +0000 |
---|---|---|
committer | Rafael Espindola <rafael.espindola@gmail.com> | 2013-05-04 03:48:37 +0000 |
commit | 3df61b7befb4b3018c9e826848462dd5053b9215 (patch) | |
tree | d65c490df517810d58accf73116a553efb220e94 /llvm/lib/Linker/LinkModules.cpp | |
parent | a8023c1c9feb9da2cef0d476af7de76100bc87dd (diff) | |
download | bcm5719-llvm-3df61b7befb4b3018c9e826848462dd5053b9215.tar.gz bcm5719-llvm-3df61b7befb4b3018c9e826848462dd5053b9215.zip |
Now that Linker.cpp is almost empty, merge it into LinkModules.cpp.
Also remove unused includes.
llvm-svn: 181100
Diffstat (limited to 'llvm/lib/Linker/LinkModules.cpp')
-rw-r--r-- | llvm/lib/Linker/LinkModules.cpp | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/llvm/lib/Linker/LinkModules.cpp b/llvm/lib/Linker/LinkModules.cpp index 74cbdadd61e..161c269ef0a 100644 --- a/llvm/lib/Linker/LinkModules.cpp +++ b/llvm/lib/Linker/LinkModules.cpp @@ -13,21 +13,15 @@ #include "llvm/Linker.h" #include "llvm-c/Linker.h" -#include "llvm/ADT/DenseSet.h" #include "llvm/ADT/Optional.h" #include "llvm/ADT/SetVector.h" -#include "llvm/ADT/SmallPtrSet.h" #include "llvm/ADT/SmallString.h" #include "llvm/IR/Constants.h" -#include "llvm/IR/DerivedTypes.h" -#include "llvm/IR/Instructions.h" #include "llvm/IR/Module.h" #include "llvm/IR/TypeFinder.h" #include "llvm/Support/Debug.h" #include "llvm/Support/raw_ostream.h" #include "llvm/Transforms/Utils/Cloning.h" -#include "llvm/Transforms/Utils/ValueMapper.h" -#include <cctype> using namespace llvm; //===----------------------------------------------------------------------===// @@ -1287,6 +1281,15 @@ bool ModuleLinker::run() { return false; } +Linker::Linker(Module *M) : Composite(M) {} + +Linker::~Linker() { +} + +bool Linker::linkInModule(Module *Src, unsigned Mode, std::string *ErrorMsg) { + return LinkModules(Composite, Src, Linker::DestroySource, ErrorMsg); +} + //===----------------------------------------------------------------------===// // LinkModules entrypoint. //===----------------------------------------------------------------------===// |