diff options
author | Chris Lattner <sabre@nondot.org> | 2012-01-03 23:47:05 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2012-01-03 23:47:05 +0000 |
commit | e22e6131281180936c5196e811e4c952549aa7ab (patch) | |
tree | f0759d1f04b4b61efe165bc65a3eddd697212241 /llvm/lib | |
parent | 134a83a799fac622ffa781efcc934d27f933d37e (diff) | |
download | bcm5719-llvm-e22e6131281180936c5196e811e4c952549aa7ab.tar.gz bcm5719-llvm-e22e6131281180936c5196e811e4c952549aa7ab.zip |
generalize LLVMContext::emitError to take a twine instead of a StringRef.
llvm-svn: 147501
Diffstat (limited to 'llvm/lib')
-rw-r--r-- | llvm/lib/VMCore/LLVMContext.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/llvm/lib/VMCore/LLVMContext.cpp b/llvm/lib/VMCore/LLVMContext.cpp index e1a9b177243..d77e996b5e4 100644 --- a/llvm/lib/VMCore/LLVMContext.cpp +++ b/llvm/lib/VMCore/LLVMContext.cpp @@ -83,11 +83,11 @@ void *LLVMContext::getInlineAsmDiagnosticContext() const { return pImpl->InlineAsmDiagContext; } -void LLVMContext::emitError(StringRef ErrorStr) { +void LLVMContext::emitError(const Twine &ErrorStr) { emitError(0U, ErrorStr); } -void LLVMContext::emitError(const Instruction *I, StringRef ErrorStr) { +void LLVMContext::emitError(const Instruction *I, const Twine &ErrorStr) { unsigned LocCookie = 0; if (const MDNode *SrcLoc = I->getMetadata("srcloc")) { if (SrcLoc->getNumOperands() != 0) @@ -97,7 +97,7 @@ void LLVMContext::emitError(const Instruction *I, StringRef ErrorStr) { return emitError(LocCookie, ErrorStr); } -void LLVMContext::emitError(unsigned LocCookie, StringRef ErrorStr) { +void LLVMContext::emitError(unsigned LocCookie, const Twine &ErrorStr) { // If there is no error handler installed, just print the error and exit. if (pImpl->InlineAsmDiagHandler == 0) { errs() << "error: " << ErrorStr << "\n"; |