Enabling --combined-json to output to file

This commit is contained in:
Ali92hm authored and Alex Beregszaszi committed 2017-09-12 21:50:22 +01:00
1 parent 1a9c503e93
commit 487ade1635
1 file changed
+5 -1
+5 -1
View File
@@ -910,7 +910,11 @@ void CommandLineInterface::handleCombinedJSON()
output[g_strSources][sourceCode.first]["AST"] = converter.toJson(m_compiler->ast(sourceCode.first));
}
}
cout << dev::jsonCompactPrint(output) << endl;
if (m_args.count(g_argOutputDir))
createJson("combined", output);
else
cout << dev::jsonCompactPrint(output) << endl;
}
void CommandLineInterface::handleAst(string const& _argStr)