mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Allow different entry scope for registerDeclarations.
This commit is contained in:
@@ -427,7 +427,12 @@ bool TypeChecker::visit(StructDefinition const& _struct)
|
||||
|
||||
bool TypeChecker::visit(FunctionDefinition const& _function)
|
||||
{
|
||||
bool isLibraryFunction = dynamic_cast<ContractDefinition const&>(*_function.scope()).isLibrary();
|
||||
bool isLibraryFunction = false;
|
||||
if (
|
||||
dynamic_cast<ContractDefinition const*>(_function.scope()) &&
|
||||
dynamic_cast<ContractDefinition const*>(_function.scope())->isLibrary()
|
||||
)
|
||||
isLibraryFunction = true;
|
||||
if (_function.isPayable())
|
||||
{
|
||||
if (isLibraryFunction)
|
||||
|
||||
Reference in New Issue
Block a user