mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Merge pull request #2307 from ethereum/compilerstack
Scanner requires only the SourcesSet state
This commit is contained in:
commit
e1519f4f27
@ -507,8 +507,8 @@ string const& CompilerStack::onChainMetadata(string const& _contractName) const
|
|||||||
|
|
||||||
Scanner const& CompilerStack::scanner(string const& _sourceName) const
|
Scanner const& CompilerStack::scanner(string const& _sourceName) const
|
||||||
{
|
{
|
||||||
if (m_stackState < ParsingSuccessful)
|
if (m_stackState < SourcesSet)
|
||||||
BOOST_THROW_EXCEPTION(CompilerError() << errinfo_comment("Parsing was not successful."));
|
BOOST_THROW_EXCEPTION(CompilerError() << errinfo_comment("No sources set."));
|
||||||
|
|
||||||
return *source(_sourceName).scanner;
|
return *source(_sourceName).scanner;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user