mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-25 13:24:46 +00:00
Revert "Introduce a string_ostream string builder facilty"
Temporarily back out commits r211749, r211752 and r211754. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@211814 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -75,7 +75,8 @@ void LLVMInitializeAnalysis(LLVMPassRegistryRef R) {
|
||||
LLVMBool LLVMVerifyModule(LLVMModuleRef M, LLVMVerifierFailureAction Action,
|
||||
char **OutMessages) {
|
||||
raw_ostream *DebugOS = Action != LLVMReturnStatusAction ? &errs() : nullptr;
|
||||
string_ostream MsgsOS;
|
||||
std::string Messages;
|
||||
raw_string_ostream MsgsOS(Messages);
|
||||
|
||||
LLVMBool Result = verifyModule(*unwrap(M), OutMessages ? &MsgsOS : DebugOS);
|
||||
|
||||
@@ -86,10 +87,8 @@ LLVMBool LLVMVerifyModule(LLVMModuleRef M, LLVMVerifierFailureAction Action,
|
||||
if (Action == LLVMAbortProcessAction && Result)
|
||||
report_fatal_error("Broken module found, compilation aborted!");
|
||||
|
||||
if (OutMessages) {
|
||||
MsgsOS << '\0';
|
||||
*OutMessages = strdup(MsgsOS.str().data());
|
||||
}
|
||||
if (OutMessages)
|
||||
*OutMessages = strdup(MsgsOS.str().c_str());
|
||||
|
||||
return Result;
|
||||
}
|
||||
|
Reference in New Issue
Block a user