aboutsummaryrefslogtreecommitdiffstats
path: root/solc/CommandLineInterface.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'solc/CommandLineInterface.cpp')
-rw-r--r--solc/CommandLineInterface.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/solc/CommandLineInterface.cpp b/solc/CommandLineInterface.cpp
index e6d8776b..9367a71c 100644
--- a/solc/CommandLineInterface.cpp
+++ b/solc/CommandLineInterface.cpp
@@ -508,6 +508,11 @@ void CommandLineInterface::createFile(string const& _fileName, string const& _da
BOOST_THROW_EXCEPTION(FileError() << errinfo_comment("Could not write to file: " + pathName));
}
+void CommandLineInterface::createJson(string const& _fileName, Json::Value const& _json)
+{
+ createFile(boost::filesystem::basename(_fileName) + string(".json"), dev::jsonCompactPrint(_json));
+}
+
bool CommandLineInterface::parseArguments(int _argc, char** _argv)
{
// Declare the supported options.