diff options
author | Alex Beregszaszi <alex@rtfs.hu> | 2016-11-15 09:04:00 +0800 |
---|---|---|
committer | Alex Beregszaszi <alex@rtfs.hu> | 2016-11-15 23:55:25 +0800 |
commit | 9719cf38e662e428ace8f3ebce9774a5338f0ce5 (patch) | |
tree | 07e441be8419b3161cedf449c2808bee082fe539 /libsolidity/interface/CompilerStack.cpp | |
parent | 0072160d7772b2f30c2c6af4428728cb31641696 (diff) | |
download | dexon-solidity-9719cf38e662e428ace8f3ebce9774a5338f0ce5.tar.gz dexon-solidity-9719cf38e662e428ace8f3ebce9774a5338f0ce5.tar.zst dexon-solidity-9719cf38e662e428ace8f3ebce9774a5338f0ce5.zip |
Move InterfaceHandler from string to JSON
Diffstat (limited to 'libsolidity/interface/CompilerStack.cpp')
-rw-r--r-- | libsolidity/interface/CompilerStack.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/libsolidity/interface/CompilerStack.cpp b/libsolidity/interface/CompilerStack.cpp index efbbd237..519027bc 100644 --- a/libsolidity/interface/CompilerStack.cpp +++ b/libsolidity/interface/CompilerStack.cpp @@ -345,17 +345,17 @@ map<string, unsigned> CompilerStack::sourceIndices() const return indices; } -string const& CompilerStack::interface(string const& _contractName) const +Json::Value const& CompilerStack::interface(string const& _contractName) const { return metadata(_contractName, DocumentationType::ABIInterface); } -string const& CompilerStack::metadata(string const& _contractName, DocumentationType _type) const +Json::Value const& CompilerStack::metadata(string const& _contractName, DocumentationType _type) const { if (!m_parseSuccessful) BOOST_THROW_EXCEPTION(CompilerError() << errinfo_comment("Parsing was not successful.")); - std::unique_ptr<string const>* doc; + std::unique_ptr<Json::Value const>* doc; Contract const& currentContract = contract(_contractName); // checks wheather we already have the documentation @@ -376,7 +376,7 @@ string const& CompilerStack::metadata(string const& _contractName, Documentation // caches the result if (!*doc) - doc->reset(new string(InterfaceHandler::documentation(*currentContract.contract, _type))); + doc->reset(new Json::Value(InterfaceHandler::documentation(*currentContract.contract, _type))); return *(*doc); } |