summaryrefslogtreecommitdiff
path: root/lib/Linker/LinkItems.cpp
diff options
context:
space:
mode:
authorDaniel Dunbar <daniel@zuster.org>2009-07-25 06:02:13 +0000
committerDaniel Dunbar <daniel@zuster.org>2009-07-25 06:02:13 +0000
commit92ccf70ad448eb02f9f273d2c70ae4708b3bd0f2 (patch)
tree79e29e5f8e24b6c70ff964e42d9b438c3b11eddf /lib/Linker/LinkItems.cpp
parent8b5ee823c2393d15c74e2dda0c46f8a2c6f40dc8 (diff)
downloadllvm-92ccf70ad448eb02f9f273d2c70ae4708b3bd0f2.tar.gz
llvm-92ccf70ad448eb02f9f273d2c70ae4708b3bd0f2.tar.bz2
llvm-92ccf70ad448eb02f9f273d2c70ae4708b3bd0f2.tar.xz
Finish migrating VMCore to StringRef/Twine based APIs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@77051 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Linker/LinkItems.cpp')
-rw-r--r--lib/Linker/LinkItems.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/Linker/LinkItems.cpp b/lib/Linker/LinkItems.cpp
index db86005876..3c9a857148 100644
--- a/lib/Linker/LinkItems.cpp
+++ b/lib/Linker/LinkItems.cpp
@@ -70,12 +70,12 @@ Linker::LinkInItems(const ItemList& Items, ItemList& NativeItems) {
/// LinkInLibrary - links one library into the HeadModule.
///
-bool Linker::LinkInLibrary(const std::string& Lib, bool& is_native) {
+bool Linker::LinkInLibrary(const StringRef &Lib, bool& is_native) {
is_native = false;
// Determine where this library lives.
sys::Path Pathname = FindLib(Lib);
if (Pathname.isEmpty())
- return error("Cannot find library '" + Lib + "'");
+ return error("Cannot find library '" + Lib.str() + "'");
// If its an archive, try to link it in
std::string Magic;
@@ -83,7 +83,7 @@ bool Linker::LinkInLibrary(const std::string& Lib, bool& is_native) {
switch (sys::IdentifyFileType(Magic.c_str(), 64)) {
default: llvm_unreachable("Bad file type identification");
case sys::Unknown_FileType:
- return warning("Supposed library '" + Lib + "' isn't a library.");
+ return warning("Supposed library '" + Lib.str() + "' isn't a library.");
case sys::Bitcode_FileType:
// LLVM ".so" file.