aboutsummaryrefslogtreecommitdiffstats
path: root/utils
diff options
context:
space:
mode:
authorMikhail Glushenkov <foldr@codedgers.com>2009-02-27 06:46:55 +0000
committerMikhail Glushenkov <foldr@codedgers.com>2009-02-27 06:46:55 +0000
commitc52551dfa20ae54fbcadd8e3d278c791bc26f225 (patch)
treee57137d107d56602c3db40ff62c72e3d36009e91 /utils
parent579214a39a45a85a86599b2839b907397165a97d (diff)
downloadexternal_llvm-c52551dfa20ae54fbcadd8e3d278c791bc26f225.zip
external_llvm-c52551dfa20ae54fbcadd8e3d278c791bc26f225.tar.gz
external_llvm-c52551dfa20ae54fbcadd8e3d278c791bc26f225.tar.bz2
'append_cmd' should split its argument.
Makes '(append_cmd "-foo a b c")' work. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@65623 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'utils')
-rw-r--r--utils/TableGen/LLVMCConfigurationEmitter.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/utils/TableGen/LLVMCConfigurationEmitter.cpp b/utils/TableGen/LLVMCConfigurationEmitter.cpp
index fc166ef..bb4321c 100644
--- a/utils/TableGen/LLVMCConfigurationEmitter.cpp
+++ b/utils/TableGen/LLVMCConfigurationEmitter.cpp
@@ -1422,7 +1422,12 @@ class EmitActionHandler {
if (ActionName == "append_cmd") {
checkNumberOfArguments(&Dag, 1);
const std::string& Cmd = InitPtrToString(Dag.getArg(0));
- O << IndentLevel << "vec.push_back(\"" << Cmd << "\");\n";
+ StrVector Out;
+ llvm::SplitString(Cmd, Out);
+
+ for (StrVector::const_iterator B = Out.begin(), E = Out.end();
+ B != E; ++B)
+ O << IndentLevel << "vec.push_back(\"" << *B << "\");\n";
}
else if (ActionName == "error") {
O << IndentLevel << "throw std::runtime_error(\"" <<