[llvm] r205109 - TableGen: don't save a StringRef to a local std::string.
Tim Northover
tnorthover at apple.com
Sat Mar 29 09:59:28 PDT 2014
Author: tnorthover
Date: Sat Mar 29 11:59:27 2014
New Revision: 205109
URL: http://llvm.org/viewvc/llvm-project?rev=205109&view=rev
Log:
TableGen: don't save a StringRef to a local std::string.
This caused a failure in some Windows builds.
Modified:
llvm/trunk/utils/TableGen/AsmWriterEmitter.cpp
Modified: llvm/trunk/utils/TableGen/AsmWriterEmitter.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/utils/TableGen/AsmWriterEmitter.cpp?rev=205109&r1=205108&r2=205109&view=diff
==============================================================================
--- llvm/trunk/utils/TableGen/AsmWriterEmitter.cpp (original)
+++ llvm/trunk/utils/TableGen/AsmWriterEmitter.cpp Sat Mar 29 11:59:27 2014
@@ -603,8 +603,8 @@ void AsmWriterEmitter::EmitGetRegisterNa
<< " switch(AltIdx) {\n"
<< " default: llvm_unreachable(\"Invalid register alt name index!\");\n";
for (unsigned i = 0, e = AltNameIndices.size(); i < e; ++i) {
- StringRef Namespace = AltNameIndices[1]->getValueAsString("Namespace");
- StringRef AltName(AltNameIndices[i]->getName());
+ std::string Namespace = AltNameIndices[1]->getValueAsString("Namespace");
+ std::string AltName(AltNameIndices[i]->getName());
O << " case " << Namespace << "::" << AltName
<< ":\n"
<< " AsmStrs = AsmStrs" << AltName << ";\n"
More information about the llvm-commits
mailing list