mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Allow path syntax for super constructor calls
This commit is contained in:
parent
0b7b174945
commit
006e5f2e1f
@ -5,6 +5,14 @@ Breaking Changes:
|
|||||||
* Type System: Disallow explicit conversions from negative literals and literals larger than ``type(uint160).max`` to ``address`` type.
|
* Type System: Disallow explicit conversions from negative literals and literals larger than ``type(uint160).max`` to ``address`` type.
|
||||||
|
|
||||||
|
|
||||||
|
Language Features:
|
||||||
|
* Super constructors can now be called using the member notation e.g. ``M.C(123)``.
|
||||||
|
|
||||||
|
|
||||||
|
AST Changes:
|
||||||
|
* New AST Node ``IdentifierPath`` replacing in many places the ``UserDefinedTypeName``
|
||||||
|
|
||||||
|
|
||||||
### 0.7.4 (unreleased)
|
### 0.7.4 (unreleased)
|
||||||
|
|
||||||
Language Features:
|
Language Features:
|
||||||
|
@ -301,7 +301,7 @@ void ContractLevelChecker::checkBaseConstructorArguments(ContractDefinition cons
|
|||||||
if (FunctionDefinition const* constructor = contract->constructor())
|
if (FunctionDefinition const* constructor = contract->constructor())
|
||||||
for (auto const& modifier: constructor->modifiers())
|
for (auto const& modifier: constructor->modifiers())
|
||||||
if (auto baseContract = dynamic_cast<ContractDefinition const*>(
|
if (auto baseContract = dynamic_cast<ContractDefinition const*>(
|
||||||
modifier->name()->annotation().referencedDeclaration
|
modifier->name().annotation().referencedDeclaration
|
||||||
))
|
))
|
||||||
{
|
{
|
||||||
if (modifier->arguments())
|
if (modifier->arguments())
|
||||||
|
@ -290,7 +290,7 @@ bool ControlFlowBuilder::visit(ModifierInvocation const& _modifierInvocation)
|
|||||||
appendControlFlow(*argument);
|
appendControlFlow(*argument);
|
||||||
|
|
||||||
auto modifierDefinition = dynamic_cast<ModifierDefinition const*>(
|
auto modifierDefinition = dynamic_cast<ModifierDefinition const*>(
|
||||||
_modifierInvocation.name()->annotation().referencedDeclaration
|
_modifierInvocation.name().annotation().referencedDeclaration
|
||||||
);
|
);
|
||||||
if (!modifierDefinition) return false;
|
if (!modifierDefinition) return false;
|
||||||
solAssert(!!modifierDefinition, "");
|
solAssert(!!modifierDefinition, "");
|
||||||
|
@ -133,7 +133,7 @@ void DeclarationTypeChecker::endVisit(UserDefinedTypeName const& _typeName)
|
|||||||
if (_typeName.annotation().type)
|
if (_typeName.annotation().type)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
Declaration const* declaration = _typeName.annotation().referencedDeclaration;
|
Declaration const* declaration = _typeName.pathNode().annotation().referencedDeclaration;
|
||||||
solAssert(declaration, "");
|
solAssert(declaration, "");
|
||||||
|
|
||||||
if (StructDefinition const* structDef = dynamic_cast<StructDefinition const*>(declaration))
|
if (StructDefinition const* structDef = dynamic_cast<StructDefinition const*>(declaration))
|
||||||
@ -390,7 +390,6 @@ void DeclarationTypeChecker::endVisit(VariableDeclaration const& _variable)
|
|||||||
}
|
}
|
||||||
|
|
||||||
_variable.annotation().type = type;
|
_variable.annotation().type = type;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void DeclarationTypeChecker::endVisit(UsingForDirective const& _usingFor)
|
void DeclarationTypeChecker::endVisit(UsingForDirective const& _usingFor)
|
||||||
|
@ -122,6 +122,18 @@ bool ImmutableValidator::visit(WhileStatement const& _whileStatement)
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void ImmutableValidator::endVisit(IdentifierPath const& _identifierPath)
|
||||||
|
{
|
||||||
|
if (auto const callableDef = dynamic_cast<CallableDeclaration const*>(_identifierPath.annotation().referencedDeclaration))
|
||||||
|
visitCallableIfNew(
|
||||||
|
*_identifierPath.annotation().requiredLookup == VirtualLookup::Virtual ?
|
||||||
|
callableDef->resolveVirtual(m_currentContract) :
|
||||||
|
*callableDef
|
||||||
|
);
|
||||||
|
|
||||||
|
solAssert(!dynamic_cast<VariableDeclaration const*>(_identifierPath.annotation().referencedDeclaration), "");
|
||||||
|
}
|
||||||
|
|
||||||
void ImmutableValidator::endVisit(Identifier const& _identifier)
|
void ImmutableValidator::endVisit(Identifier const& _identifier)
|
||||||
{
|
{
|
||||||
if (auto const callableDef = dynamic_cast<CallableDeclaration const*>(_identifier.annotation().referencedDeclaration))
|
if (auto const callableDef = dynamic_cast<CallableDeclaration const*>(_identifier.annotation().referencedDeclaration))
|
||||||
|
@ -53,6 +53,7 @@ private:
|
|||||||
bool visit(MemberAccess const& _memberAccess);
|
bool visit(MemberAccess const& _memberAccess);
|
||||||
bool visit(IfStatement const& _ifStatement);
|
bool visit(IfStatement const& _ifStatement);
|
||||||
bool visit(WhileStatement const& _whileStatement);
|
bool visit(WhileStatement const& _whileStatement);
|
||||||
|
void endVisit(IdentifierPath const& _identifierPath);
|
||||||
void endVisit(Identifier const& _identifier);
|
void endVisit(Identifier const& _identifier);
|
||||||
void endVisit(Return const& _return);
|
void endVisit(Return const& _return);
|
||||||
|
|
||||||
|
@ -400,7 +400,7 @@ void NameAndTypeResolver::linearizeBaseContracts(ContractDefinition& _contract)
|
|||||||
list<list<ContractDefinition const*>> input(1, list<ContractDefinition const*>{});
|
list<list<ContractDefinition const*>> input(1, list<ContractDefinition const*>{});
|
||||||
for (ASTPointer<InheritanceSpecifier> const& baseSpecifier: _contract.baseContracts())
|
for (ASTPointer<InheritanceSpecifier> const& baseSpecifier: _contract.baseContracts())
|
||||||
{
|
{
|
||||||
UserDefinedTypeName const& baseName = baseSpecifier->name();
|
IdentifierPath const& baseName = baseSpecifier->name();
|
||||||
auto base = dynamic_cast<ContractDefinition const*>(baseName.annotation().referencedDeclaration);
|
auto base = dynamic_cast<ContractDefinition const*>(baseName.annotation().referencedDeclaration);
|
||||||
if (!base)
|
if (!base)
|
||||||
m_errorReporter.fatalTypeError(8758_error, baseName.location(), "Contract expected.");
|
m_errorReporter.fatalTypeError(8758_error, baseName.location(), "Contract expected.");
|
||||||
|
@ -154,12 +154,12 @@ vector<ContractDefinition const*> resolveDirectBaseContracts(ContractDefinition
|
|||||||
return resolvedContracts;
|
return resolvedContracts;
|
||||||
}
|
}
|
||||||
|
|
||||||
vector<ASTPointer<UserDefinedTypeName>> sortByContract(vector<ASTPointer<UserDefinedTypeName>> const& _list)
|
vector<ASTPointer<IdentifierPath>> sortByContract(vector<ASTPointer<IdentifierPath>> const& _list)
|
||||||
{
|
{
|
||||||
auto sorted = _list;
|
auto sorted = _list;
|
||||||
|
|
||||||
stable_sort(sorted.begin(), sorted.end(),
|
stable_sort(sorted.begin(), sorted.end(),
|
||||||
[] (ASTPointer<UserDefinedTypeName> _a, ASTPointer<UserDefinedTypeName> _b) {
|
[] (ASTPointer<IdentifierPath> _a, ASTPointer<IdentifierPath> _b) {
|
||||||
if (!_a || !_b)
|
if (!_a || !_b)
|
||||||
return _a < _b;
|
return _a < _b;
|
||||||
|
|
||||||
@ -773,7 +773,7 @@ set<ContractDefinition const*, OverrideChecker::CompareByID> OverrideChecker::re
|
|||||||
{
|
{
|
||||||
set<ContractDefinition const*, CompareByID> resolved;
|
set<ContractDefinition const*, CompareByID> resolved;
|
||||||
|
|
||||||
for (ASTPointer<UserDefinedTypeName> const& override: _overrides.overrides())
|
for (ASTPointer<IdentifierPath> const& override: _overrides.overrides())
|
||||||
{
|
{
|
||||||
Declaration const* decl = override->annotation().referencedDeclaration;
|
Declaration const* decl = override->annotation().referencedDeclaration;
|
||||||
solAssert(decl, "Expected declaration to be resolved.");
|
solAssert(decl, "Expected declaration to be resolved.");
|
||||||
@ -798,7 +798,7 @@ void OverrideChecker::checkOverrideList(OverrideProxy _item, OverrideProxyBySign
|
|||||||
if (_item.overrides() && specifiedContracts.size() != _item.overrides()->overrides().size())
|
if (_item.overrides() && specifiedContracts.size() != _item.overrides()->overrides().size())
|
||||||
{
|
{
|
||||||
// Sort by contract id to find duplicate for error reporting
|
// Sort by contract id to find duplicate for error reporting
|
||||||
vector<ASTPointer<UserDefinedTypeName>> list =
|
vector<ASTPointer<IdentifierPath>> list =
|
||||||
sortByContract(_item.overrides()->overrides());
|
sortByContract(_item.overrides()->overrides());
|
||||||
|
|
||||||
// Find duplicates and output error
|
// Find duplicates and output error
|
||||||
@ -818,7 +818,7 @@ void OverrideChecker::checkOverrideList(OverrideProxy _item, OverrideProxyBySign
|
|||||||
list[i]->location(),
|
list[i]->location(),
|
||||||
ssl,
|
ssl,
|
||||||
"Duplicate contract \"" +
|
"Duplicate contract \"" +
|
||||||
joinHumanReadable(list[i]->namePath(), ".") +
|
joinHumanReadable(list[i]->path(), ".") +
|
||||||
"\" found in override list of \"" +
|
"\" found in override list of \"" +
|
||||||
_item.name() +
|
_item.name() +
|
||||||
"\"."
|
"\"."
|
||||||
|
@ -217,7 +217,7 @@ struct OverrideSpecifierChecker: public PostTypeChecker::Checker
|
|||||||
|
|
||||||
void endVisit(OverrideSpecifier const& _overrideSpecifier) override
|
void endVisit(OverrideSpecifier const& _overrideSpecifier) override
|
||||||
{
|
{
|
||||||
for (ASTPointer<UserDefinedTypeName> const& override: _overrideSpecifier.overrides())
|
for (ASTPointer<IdentifierPath> const& override: _overrideSpecifier.overrides())
|
||||||
{
|
{
|
||||||
Declaration const* decl = override->annotation().referencedDeclaration;
|
Declaration const* decl = override->annotation().referencedDeclaration;
|
||||||
solAssert(decl, "Expected declaration to be resolved.");
|
solAssert(decl, "Expected declaration to be resolved.");
|
||||||
|
@ -183,11 +183,6 @@ void ReferencesResolver::endVisit(IdentifierPath const& _path)
|
|||||||
_path.annotation().referencedDeclaration = declaration;
|
_path.annotation().referencedDeclaration = declaration;
|
||||||
}
|
}
|
||||||
|
|
||||||
void ReferencesResolver::endVisit(UserDefinedTypeName const& _typeName)
|
|
||||||
{
|
|
||||||
_typeName.annotation().referencedDeclaration = _typeName.pathNode()->annotation().referencedDeclaration;
|
|
||||||
}
|
|
||||||
|
|
||||||
bool ReferencesResolver::visit(InlineAssembly const& _inlineAssembly)
|
bool ReferencesResolver::visit(InlineAssembly const& _inlineAssembly)
|
||||||
{
|
{
|
||||||
m_resolver.warnVariablesNamedLikeInstructions();
|
m_resolver.warnVariablesNamedLikeInstructions();
|
||||||
|
@ -82,8 +82,7 @@ private:
|
|||||||
void endVisit(FunctionDefinition const& _functionDefinition) override;
|
void endVisit(FunctionDefinition const& _functionDefinition) override;
|
||||||
bool visit(ModifierDefinition const& _modifierDefinition) override;
|
bool visit(ModifierDefinition const& _modifierDefinition) override;
|
||||||
void endVisit(ModifierDefinition const& _modifierDefinition) override;
|
void endVisit(ModifierDefinition const& _modifierDefinition) override;
|
||||||
void endVisit(IdentifierPath const& _typeName) override;
|
void endVisit(IdentifierPath const& _path) override;
|
||||||
void endVisit(UserDefinedTypeName const& _typeName) override;
|
|
||||||
bool visit(InlineAssembly const& _inlineAssembly) override;
|
bool visit(InlineAssembly const& _inlineAssembly) override;
|
||||||
bool visit(Return const& _return) override;
|
bool visit(Return const& _return) override;
|
||||||
|
|
||||||
|
@ -351,6 +351,9 @@ bool TypeChecker::visit(FunctionDefinition const& _function)
|
|||||||
if (_function.overrides() && _function.isFree())
|
if (_function.overrides() && _function.isFree())
|
||||||
m_errorReporter.syntaxError(1750_error, _function.location(), "Free functions cannot override.");
|
m_errorReporter.syntaxError(1750_error, _function.location(), "Free functions cannot override.");
|
||||||
|
|
||||||
|
if (!_function.modifiers().empty() && _function.isFree())
|
||||||
|
m_errorReporter.syntaxError(5811_error, _function.location(), "Free functions cannot have modifiers.");
|
||||||
|
|
||||||
if (_function.isPayable())
|
if (_function.isPayable())
|
||||||
{
|
{
|
||||||
if (_function.libraryFunction())
|
if (_function.libraryFunction())
|
||||||
@ -443,7 +446,7 @@ bool TypeChecker::visit(FunctionDefinition const& _function)
|
|||||||
*modifier,
|
*modifier,
|
||||||
_function.isConstructor() ? baseContracts : vector<ContractDefinition const*>()
|
_function.isConstructor() ? baseContracts : vector<ContractDefinition const*>()
|
||||||
);
|
);
|
||||||
Declaration const* decl = &dereference(*modifier->name());
|
Declaration const* decl = &dereference(modifier->name());
|
||||||
if (modifiers.count(decl))
|
if (modifiers.count(decl))
|
||||||
{
|
{
|
||||||
if (dynamic_cast<ContractDefinition const*>(decl))
|
if (dynamic_cast<ContractDefinition const*>(decl))
|
||||||
@ -627,9 +630,9 @@ void TypeChecker::visitManually(
|
|||||||
for (ASTPointer<Expression> const& argument: arguments)
|
for (ASTPointer<Expression> const& argument: arguments)
|
||||||
argument->accept(*this);
|
argument->accept(*this);
|
||||||
|
|
||||||
_modifier.name()->accept(*this);
|
_modifier.name().accept(*this);
|
||||||
|
|
||||||
auto const* declaration = &dereference(*_modifier.name());
|
auto const* declaration = &dereference(_modifier.name());
|
||||||
vector<ASTPointer<VariableDeclaration>> emptyParameterList;
|
vector<ASTPointer<VariableDeclaration>> emptyParameterList;
|
||||||
vector<ASTPointer<VariableDeclaration>> const* parameters = nullptr;
|
vector<ASTPointer<VariableDeclaration>> const* parameters = nullptr;
|
||||||
if (auto modifierDecl = dynamic_cast<ModifierDefinition const*>(declaration))
|
if (auto modifierDecl = dynamic_cast<ModifierDefinition const*>(declaration))
|
||||||
@ -2534,7 +2537,7 @@ void TypeChecker::endVisit(NewExpression const& _newExpression)
|
|||||||
|
|
||||||
if (auto contractName = dynamic_cast<UserDefinedTypeName const*>(&_newExpression.typeName()))
|
if (auto contractName = dynamic_cast<UserDefinedTypeName const*>(&_newExpression.typeName()))
|
||||||
{
|
{
|
||||||
auto contract = dynamic_cast<ContractDefinition const*>(&dereference(*contractName));
|
auto contract = dynamic_cast<ContractDefinition const*>(&dereference(contractName->pathNode()));
|
||||||
|
|
||||||
if (!contract)
|
if (!contract)
|
||||||
m_errorReporter.fatalTypeError(5540_error, _newExpression.location(), "Identifier is not a contract.");
|
m_errorReporter.fatalTypeError(5540_error, _newExpression.location(), "Identifier is not a contract.");
|
||||||
@ -3196,6 +3199,23 @@ bool TypeChecker::visit(Identifier const& _identifier)
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void TypeChecker::endVisit(IdentifierPath const& _identifierPath)
|
||||||
|
{
|
||||||
|
if (
|
||||||
|
dynamic_cast<CallableDeclaration const*>(_identifierPath.annotation().referencedDeclaration) &&
|
||||||
|
_identifierPath.path().size() == 1
|
||||||
|
)
|
||||||
|
_identifierPath.annotation().requiredLookup = VirtualLookup::Virtual;
|
||||||
|
else
|
||||||
|
_identifierPath.annotation().requiredLookup = VirtualLookup::Static;
|
||||||
|
}
|
||||||
|
|
||||||
|
void TypeChecker::endVisit(UserDefinedTypeName const& _userDefinedTypeName)
|
||||||
|
{
|
||||||
|
if (!_userDefinedTypeName.annotation().type)
|
||||||
|
_userDefinedTypeName.annotation().type = _userDefinedTypeName.pathNode().annotation().referencedDeclaration->type();
|
||||||
|
}
|
||||||
|
|
||||||
void TypeChecker::endVisit(ElementaryTypeNameExpression const& _expr)
|
void TypeChecker::endVisit(ElementaryTypeNameExpression const& _expr)
|
||||||
{
|
{
|
||||||
_expr.annotation().type = TypeProvider::typeType(TypeProvider::fromElementaryTypeName(_expr.type().typeName(), _expr.type().stateMutability()));
|
_expr.annotation().type = TypeProvider::typeType(TypeProvider::fromElementaryTypeName(_expr.type().typeName(), _expr.type().stateMutability()));
|
||||||
@ -3293,10 +3313,10 @@ Declaration const& TypeChecker::dereference(Identifier const& _identifier) const
|
|||||||
return *_identifier.annotation().referencedDeclaration;
|
return *_identifier.annotation().referencedDeclaration;
|
||||||
}
|
}
|
||||||
|
|
||||||
Declaration const& TypeChecker::dereference(UserDefinedTypeName const& _typeName) const
|
Declaration const& TypeChecker::dereference(IdentifierPath const& _path) const
|
||||||
{
|
{
|
||||||
solAssert(!!_typeName.annotation().referencedDeclaration, "Declaration not stored.");
|
solAssert(!!_path.annotation().referencedDeclaration, "Declaration not stored.");
|
||||||
return *_typeName.annotation().referencedDeclaration;
|
return *_path.annotation().referencedDeclaration;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool TypeChecker::expectType(Expression const& _expression, Type const& _expectedType)
|
bool TypeChecker::expectType(Expression const& _expression, Type const& _expectedType)
|
||||||
|
@ -141,6 +141,8 @@ private:
|
|||||||
bool visit(IndexAccess const& _indexAccess) override;
|
bool visit(IndexAccess const& _indexAccess) override;
|
||||||
bool visit(IndexRangeAccess const& _indexRangeAccess) override;
|
bool visit(IndexRangeAccess const& _indexRangeAccess) override;
|
||||||
bool visit(Identifier const& _identifier) override;
|
bool visit(Identifier const& _identifier) override;
|
||||||
|
void endVisit(IdentifierPath const& _identifierPath) override;
|
||||||
|
void endVisit(UserDefinedTypeName const& _userDefinedTypeName) override;
|
||||||
void endVisit(ElementaryTypeNameExpression const& _expr) override;
|
void endVisit(ElementaryTypeNameExpression const& _expr) override;
|
||||||
void endVisit(Literal const& _literal) override;
|
void endVisit(Literal const& _literal) override;
|
||||||
void endVisit(UsingForDirective const& _usingForDirective) override;
|
void endVisit(UsingForDirective const& _usingForDirective) override;
|
||||||
@ -153,7 +155,7 @@ private:
|
|||||||
/// @returns the referenced declaration and throws on error.
|
/// @returns the referenced declaration and throws on error.
|
||||||
Declaration const& dereference(Identifier const& _identifier) const;
|
Declaration const& dereference(Identifier const& _identifier) const;
|
||||||
/// @returns the referenced declaration and throws on error.
|
/// @returns the referenced declaration and throws on error.
|
||||||
Declaration const& dereference(UserDefinedTypeName const& _typeName) const;
|
Declaration const& dereference(IdentifierPath const& _path) const;
|
||||||
|
|
||||||
std::vector<Declaration const*> cleanOverloadedDeclarations(
|
std::vector<Declaration const*> cleanOverloadedDeclarations(
|
||||||
Identifier const& _reference,
|
Identifier const& _reference,
|
||||||
|
@ -432,13 +432,12 @@ void ViewPureChecker::endVisit(IndexRangeAccess const& _indexRangeAccess)
|
|||||||
|
|
||||||
void ViewPureChecker::endVisit(ModifierInvocation const& _modifier)
|
void ViewPureChecker::endVisit(ModifierInvocation const& _modifier)
|
||||||
{
|
{
|
||||||
solAssert(_modifier.name(), "");
|
if (ModifierDefinition const* mod = dynamic_cast<decltype(mod)>(_modifier.name().annotation().referencedDeclaration))
|
||||||
if (ModifierDefinition const* mod = dynamic_cast<decltype(mod)>(_modifier.name()->annotation().referencedDeclaration))
|
|
||||||
{
|
{
|
||||||
MutabilityAndLocation const& mutAndLocation = modifierMutability(*mod);
|
MutabilityAndLocation const& mutAndLocation = modifierMutability(*mod);
|
||||||
reportMutability(mutAndLocation.mutability, _modifier.location(), mutAndLocation.location);
|
reportMutability(mutAndLocation.mutability, _modifier.location(), mutAndLocation.location);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
solAssert(dynamic_cast<ContractDefinition const*>(_modifier.name()->annotation().referencedDeclaration), "");
|
solAssert(dynamic_cast<ContractDefinition const*>(_modifier.name().annotation().referencedDeclaration), "");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -460,11 +460,6 @@ EventDefinitionAnnotation& EventDefinition::annotation() const
|
|||||||
return initAnnotation<EventDefinitionAnnotation>();
|
return initAnnotation<EventDefinitionAnnotation>();
|
||||||
}
|
}
|
||||||
|
|
||||||
UserDefinedTypeNameAnnotation& UserDefinedTypeName::annotation() const
|
|
||||||
{
|
|
||||||
return initAnnotation<UserDefinedTypeNameAnnotation>();
|
|
||||||
}
|
|
||||||
|
|
||||||
SourceUnit const& Scopable::sourceUnit() const
|
SourceUnit const& Scopable::sourceUnit() const
|
||||||
{
|
{
|
||||||
ASTNode const* s = scope();
|
ASTNode const* s = scope();
|
||||||
|
@ -558,7 +558,7 @@ private:
|
|||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A sequence of identifiers separated by dots
|
* A sequence of identifiers separated by dots used outside the expression context. Inside the expression context, this is a sequence of Identifier and MemberAccess.
|
||||||
*/
|
*/
|
||||||
class IdentifierPath: public ASTNode
|
class IdentifierPath: public ASTNode
|
||||||
{
|
{
|
||||||
@ -584,7 +584,7 @@ public:
|
|||||||
InheritanceSpecifier(
|
InheritanceSpecifier(
|
||||||
int64_t _id,
|
int64_t _id,
|
||||||
SourceLocation const& _location,
|
SourceLocation const& _location,
|
||||||
ASTPointer<UserDefinedTypeName> _baseName,
|
ASTPointer<IdentifierPath> _baseName,
|
||||||
std::unique_ptr<std::vector<ASTPointer<Expression>>> _arguments
|
std::unique_ptr<std::vector<ASTPointer<Expression>>> _arguments
|
||||||
):
|
):
|
||||||
ASTNode(_id, _location), m_baseName(std::move(_baseName)), m_arguments(std::move(_arguments))
|
ASTNode(_id, _location), m_baseName(std::move(_baseName)), m_arguments(std::move(_arguments))
|
||||||
@ -595,14 +595,14 @@ public:
|
|||||||
void accept(ASTVisitor& _visitor) override;
|
void accept(ASTVisitor& _visitor) override;
|
||||||
void accept(ASTConstVisitor& _visitor) const override;
|
void accept(ASTConstVisitor& _visitor) const override;
|
||||||
|
|
||||||
UserDefinedTypeName const& name() const { return *m_baseName; }
|
IdentifierPath const& name() const { return *m_baseName; }
|
||||||
// Returns nullptr if no argument list was given (``C``).
|
// Returns nullptr if no argument list was given (``C``).
|
||||||
// If an argument list is given (``C(...)``), the arguments are returned
|
// If an argument list is given (``C(...)``), the arguments are returned
|
||||||
// as a vector of expressions. Note that this vector can be empty (``C()``).
|
// as a vector of expressions. Note that this vector can be empty (``C()``).
|
||||||
std::vector<ASTPointer<Expression>> const* arguments() const { return m_arguments.get(); }
|
std::vector<ASTPointer<Expression>> const* arguments() const { return m_arguments.get(); }
|
||||||
|
|
||||||
private:
|
private:
|
||||||
ASTPointer<UserDefinedTypeName> m_baseName;
|
ASTPointer<IdentifierPath> m_baseName;
|
||||||
std::unique_ptr<std::vector<ASTPointer<Expression>>> m_arguments;
|
std::unique_ptr<std::vector<ASTPointer<Expression>>> m_arguments;
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -617,7 +617,7 @@ public:
|
|||||||
UsingForDirective(
|
UsingForDirective(
|
||||||
int64_t _id,
|
int64_t _id,
|
||||||
SourceLocation const& _location,
|
SourceLocation const& _location,
|
||||||
ASTPointer<UserDefinedTypeName> _libraryName,
|
ASTPointer<IdentifierPath> _libraryName,
|
||||||
ASTPointer<TypeName> _typeName
|
ASTPointer<TypeName> _typeName
|
||||||
):
|
):
|
||||||
ASTNode(_id, _location), m_libraryName(std::move(_libraryName)), m_typeName(std::move(_typeName))
|
ASTNode(_id, _location), m_libraryName(std::move(_libraryName)), m_typeName(std::move(_typeName))
|
||||||
@ -628,12 +628,12 @@ public:
|
|||||||
void accept(ASTVisitor& _visitor) override;
|
void accept(ASTVisitor& _visitor) override;
|
||||||
void accept(ASTConstVisitor& _visitor) const override;
|
void accept(ASTConstVisitor& _visitor) const override;
|
||||||
|
|
||||||
UserDefinedTypeName const& libraryName() const { return *m_libraryName; }
|
IdentifierPath const& libraryName() const { return *m_libraryName; }
|
||||||
/// @returns the type name the library is attached to, null for `*`.
|
/// @returns the type name the library is attached to, null for `*`.
|
||||||
TypeName const* typeName() const { return m_typeName.get(); }
|
TypeName const* typeName() const { return m_typeName.get(); }
|
||||||
|
|
||||||
private:
|
private:
|
||||||
ASTPointer<UserDefinedTypeName> m_libraryName;
|
ASTPointer<IdentifierPath> m_libraryName;
|
||||||
ASTPointer<TypeName> m_typeName;
|
ASTPointer<TypeName> m_typeName;
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -792,7 +792,7 @@ public:
|
|||||||
OverrideSpecifier(
|
OverrideSpecifier(
|
||||||
int64_t _id,
|
int64_t _id,
|
||||||
SourceLocation const& _location,
|
SourceLocation const& _location,
|
||||||
std::vector<ASTPointer<UserDefinedTypeName>> _overrides
|
std::vector<ASTPointer<IdentifierPath>> _overrides
|
||||||
):
|
):
|
||||||
ASTNode(_id, _location),
|
ASTNode(_id, _location),
|
||||||
m_overrides(std::move(_overrides))
|
m_overrides(std::move(_overrides))
|
||||||
@ -803,10 +803,10 @@ public:
|
|||||||
void accept(ASTConstVisitor& _visitor) const override;
|
void accept(ASTConstVisitor& _visitor) const override;
|
||||||
|
|
||||||
/// @returns the list of specific overrides, if any
|
/// @returns the list of specific overrides, if any
|
||||||
std::vector<ASTPointer<UserDefinedTypeName>> const& overrides() const { return m_overrides; }
|
std::vector<ASTPointer<IdentifierPath>> const& overrides() const { return m_overrides; }
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
std::vector<ASTPointer<UserDefinedTypeName>> m_overrides;
|
std::vector<ASTPointer<IdentifierPath>> m_overrides;
|
||||||
};
|
};
|
||||||
|
|
||||||
class FunctionDefinition: public CallableDeclaration, public StructurallyDocumented, public ImplementationOptional, public ScopeOpener
|
class FunctionDefinition: public CallableDeclaration, public StructurallyDocumented, public ImplementationOptional, public ScopeOpener
|
||||||
@ -1077,7 +1077,7 @@ public:
|
|||||||
ModifierInvocation(
|
ModifierInvocation(
|
||||||
int64_t _id,
|
int64_t _id,
|
||||||
SourceLocation const& _location,
|
SourceLocation const& _location,
|
||||||
ASTPointer<Identifier> _name,
|
ASTPointer<IdentifierPath> _name,
|
||||||
std::unique_ptr<std::vector<ASTPointer<Expression>>> _arguments
|
std::unique_ptr<std::vector<ASTPointer<Expression>>> _arguments
|
||||||
):
|
):
|
||||||
ASTNode(_id, _location), m_modifierName(std::move(_name)), m_arguments(std::move(_arguments))
|
ASTNode(_id, _location), m_modifierName(std::move(_name)), m_arguments(std::move(_arguments))
|
||||||
@ -1088,14 +1088,14 @@ public:
|
|||||||
void accept(ASTVisitor& _visitor) override;
|
void accept(ASTVisitor& _visitor) override;
|
||||||
void accept(ASTConstVisitor& _visitor) const override;
|
void accept(ASTConstVisitor& _visitor) const override;
|
||||||
|
|
||||||
ASTPointer<Identifier> const& name() const { return m_modifierName; }
|
IdentifierPath& name() const { return *m_modifierName; }
|
||||||
// Returns nullptr if no argument list was given (``mod``).
|
// Returns nullptr if no argument list was given (``mod``).
|
||||||
// If an argument list is given (``mod(...)``), the arguments are returned
|
// If an argument list is given (``mod(...)``), the arguments are returned
|
||||||
// as a vector of expressions. Note that this vector can be empty (``mod()``).
|
// as a vector of expressions. Note that this vector can be empty (``mod()``).
|
||||||
std::vector<ASTPointer<Expression>> const* arguments() const { return m_arguments.get(); }
|
std::vector<ASTPointer<Expression>> const* arguments() const { return m_arguments.get(); }
|
||||||
|
|
||||||
private:
|
private:
|
||||||
ASTPointer<Identifier> m_modifierName;
|
ASTPointer<IdentifierPath> m_modifierName;
|
||||||
std::unique_ptr<std::vector<ASTPointer<Expression>>> m_arguments;
|
std::unique_ptr<std::vector<ASTPointer<Expression>>> m_arguments;
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -1225,15 +1225,15 @@ class UserDefinedTypeName: public TypeName
|
|||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
UserDefinedTypeName(int64_t _id, SourceLocation const& _location, ASTPointer<IdentifierPath> _namePath):
|
UserDefinedTypeName(int64_t _id, SourceLocation const& _location, ASTPointer<IdentifierPath> _namePath):
|
||||||
TypeName(_id, _location), m_namePath(std::move(_namePath)) {}
|
TypeName(_id, _location), m_namePath(std::move(_namePath))
|
||||||
|
{
|
||||||
|
solAssert(m_namePath != nullptr, "Name cannot be null.");
|
||||||
|
}
|
||||||
void accept(ASTVisitor& _visitor) override;
|
void accept(ASTVisitor& _visitor) override;
|
||||||
void accept(ASTConstVisitor& _visitor) const override;
|
void accept(ASTConstVisitor& _visitor) const override;
|
||||||
|
|
||||||
std::vector<ASTString> const& namePath() const { return m_namePath->path(); }
|
std::vector<ASTString> const& namePath() const { return m_namePath->path(); }
|
||||||
ASTPointer<IdentifierPath> const& pathNode() const { return m_namePath; }
|
IdentifierPath& pathNode() const { return *m_namePath; }
|
||||||
|
|
||||||
UserDefinedTypeNameAnnotation& annotation() const override;
|
|
||||||
|
|
||||||
private:
|
private:
|
||||||
ASTPointer<IdentifierPath> m_namePath;
|
ASTPointer<IdentifierPath> m_namePath;
|
||||||
|
@ -233,16 +233,12 @@ struct TypeNameAnnotation: ASTAnnotation
|
|||||||
TypePointer type = nullptr;
|
TypePointer type = nullptr;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct IdentifierPathAnnotation: TypeNameAnnotation
|
struct IdentifierPathAnnotation: ASTAnnotation
|
||||||
{
|
|
||||||
/// Referenced declaration, set during reference resolution stage.
|
|
||||||
Declaration const* referencedDeclaration = nullptr;
|
|
||||||
};
|
|
||||||
|
|
||||||
struct UserDefinedTypeNameAnnotation: TypeNameAnnotation
|
|
||||||
{
|
{
|
||||||
/// Referenced declaration, set during reference resolution stage.
|
/// Referenced declaration, set during reference resolution stage.
|
||||||
Declaration const* referencedDeclaration = nullptr;
|
Declaration const* referencedDeclaration = nullptr;
|
||||||
|
/// What kind of lookup needs to be done (static, virtual, super) find the declaration.
|
||||||
|
SetOnce<VirtualLookup> requiredLookup;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct ExpressionAnnotation: ASTAnnotation
|
struct ExpressionAnnotation: ASTAnnotation
|
||||||
|
@ -493,7 +493,7 @@ bool ASTJsonConverter::visit(ModifierDefinition const& _node)
|
|||||||
bool ASTJsonConverter::visit(ModifierInvocation const& _node)
|
bool ASTJsonConverter::visit(ModifierInvocation const& _node)
|
||||||
{
|
{
|
||||||
setJsonNode(_node, "ModifierInvocation", {
|
setJsonNode(_node, "ModifierInvocation", {
|
||||||
make_pair("modifierName", toJson(*_node.name())),
|
make_pair("modifierName", toJson(_node.name())),
|
||||||
make_pair("arguments", _node.arguments() ? toJson(*_node.arguments()) : Json::nullValue)
|
make_pair("arguments", _node.arguments() ? toJson(*_node.arguments()) : Json::nullValue)
|
||||||
});
|
});
|
||||||
return false;
|
return false;
|
||||||
@ -528,8 +528,8 @@ bool ASTJsonConverter::visit(ElementaryTypeName const& _node)
|
|||||||
bool ASTJsonConverter::visit(UserDefinedTypeName const& _node)
|
bool ASTJsonConverter::visit(UserDefinedTypeName const& _node)
|
||||||
{
|
{
|
||||||
setJsonNode(_node, "UserDefinedTypeName", {
|
setJsonNode(_node, "UserDefinedTypeName", {
|
||||||
make_pair("pathNode", toJson(*_node.pathNode())),
|
make_pair("pathNode", toJson(_node.pathNode())),
|
||||||
make_pair("referencedDeclaration", idOrNull(_node.annotation().referencedDeclaration)),
|
make_pair("referencedDeclaration", idOrNull(_node.pathNode().annotation().referencedDeclaration)),
|
||||||
make_pair("typeDescriptions", typePointerToJson(_node.annotation().type, true))
|
make_pair("typeDescriptions", typePointerToJson(_node.annotation().type, true))
|
||||||
});
|
});
|
||||||
return false;
|
return false;
|
||||||
|
@ -116,7 +116,7 @@ ASTPointer<ASTNode> ASTJsonImporter::convertJsonToASTNode(Json::Value const& _js
|
|||||||
if (nodeType == "ContractDefinition")
|
if (nodeType == "ContractDefinition")
|
||||||
return createContractDefinition(_json);
|
return createContractDefinition(_json);
|
||||||
if (nodeType == "IdentifierPath")
|
if (nodeType == "IdentifierPath")
|
||||||
return createIdentifier(_json);
|
return createIdentifierPath(_json);
|
||||||
if (nodeType == "InheritanceSpecifier")
|
if (nodeType == "InheritanceSpecifier")
|
||||||
return createInheritanceSpecifier(_json);
|
return createInheritanceSpecifier(_json);
|
||||||
if (nodeType == "UsingForDirective")
|
if (nodeType == "UsingForDirective")
|
||||||
@ -309,12 +309,13 @@ ASTPointer<IdentifierPath> ASTJsonImporter::createIdentifierPath(Json::Value con
|
|||||||
vector<string> strs;
|
vector<string> strs;
|
||||||
string nameString = member(_node, "name").asString();
|
string nameString = member(_node, "name").asString();
|
||||||
boost::algorithm::split(strs, nameString, boost::is_any_of("."));
|
boost::algorithm::split(strs, nameString, boost::is_any_of("."));
|
||||||
|
astAssert(!strs.empty(), "Expected at least one element in IdentifierPath.");
|
||||||
for (string s: strs)
|
for (string s: strs)
|
||||||
|
{
|
||||||
|
astAssert(!s.empty(), "Expected non-empty string for IdentifierPath element.");
|
||||||
namePath.emplace_back(s);
|
namePath.emplace_back(s);
|
||||||
return createASTNode<IdentifierPath>(
|
}
|
||||||
_node,
|
return createASTNode<IdentifierPath>(_node, namePath);
|
||||||
namePath
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
ASTPointer<InheritanceSpecifier> ASTJsonImporter::createInheritanceSpecifier(Json::Value const& _node)
|
ASTPointer<InheritanceSpecifier> ASTJsonImporter::createInheritanceSpecifier(Json::Value const& _node)
|
||||||
@ -324,7 +325,7 @@ ASTPointer<InheritanceSpecifier> ASTJsonImporter::createInheritanceSpecifier(Jso
|
|||||||
arguments.push_back(convertJsonToASTNode<Expression>(arg));
|
arguments.push_back(convertJsonToASTNode<Expression>(arg));
|
||||||
return createASTNode<InheritanceSpecifier>(
|
return createASTNode<InheritanceSpecifier>(
|
||||||
_node,
|
_node,
|
||||||
createUserDefinedTypeName(member(_node, "baseName")),
|
createIdentifierPath(member(_node, "baseName")),
|
||||||
member(_node, "arguments").isNull() ? nullptr : make_unique<std::vector<ASTPointer<Expression>>>(arguments)
|
member(_node, "arguments").isNull() ? nullptr : make_unique<std::vector<ASTPointer<Expression>>>(arguments)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
@ -333,7 +334,7 @@ ASTPointer<UsingForDirective> ASTJsonImporter::createUsingForDirective(Json::Val
|
|||||||
{
|
{
|
||||||
return createASTNode<UsingForDirective>(
|
return createASTNode<UsingForDirective>(
|
||||||
_node,
|
_node,
|
||||||
createUserDefinedTypeName(member(_node, "libraryName")),
|
createIdentifierPath(member(_node, "libraryName")),
|
||||||
_node["typeName"].isNull() ? nullptr : convertJsonToASTNode<TypeName>(_node["typeName"])
|
_node["typeName"].isNull() ? nullptr : convertJsonToASTNode<TypeName>(_node["typeName"])
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
@ -383,10 +384,10 @@ ASTPointer<ParameterList> ASTJsonImporter::createParameterList(Json::Value const
|
|||||||
|
|
||||||
ASTPointer<OverrideSpecifier> ASTJsonImporter::createOverrideSpecifier(Json::Value const& _node)
|
ASTPointer<OverrideSpecifier> ASTJsonImporter::createOverrideSpecifier(Json::Value const& _node)
|
||||||
{
|
{
|
||||||
std::vector<ASTPointer<UserDefinedTypeName>> overrides;
|
std::vector<ASTPointer<IdentifierPath>> overrides;
|
||||||
|
|
||||||
for (auto& param: _node["overrides"])
|
for (auto& param: _node["overrides"])
|
||||||
overrides.push_back(createUserDefinedTypeName(param));
|
overrides.push_back(createIdentifierPath(param));
|
||||||
|
|
||||||
return createASTNode<OverrideSpecifier>(
|
return createASTNode<OverrideSpecifier>(
|
||||||
_node,
|
_node,
|
||||||
@ -499,7 +500,7 @@ ASTPointer<ModifierInvocation> ASTJsonImporter::createModifierInvocation(Json::V
|
|||||||
arguments.push_back(convertJsonToASTNode<Expression>(arg));
|
arguments.push_back(convertJsonToASTNode<Expression>(arg));
|
||||||
return createASTNode<ModifierInvocation>(
|
return createASTNode<ModifierInvocation>(
|
||||||
_node,
|
_node,
|
||||||
createIdentifier(member(_node, "modifierName")),
|
createIdentifierPath(member(_node, "modifierName")),
|
||||||
member(_node, "arguments").isNull() ? nullptr : make_unique<std::vector<ASTPointer<Expression>>>(arguments)
|
member(_node, "arguments").isNull() ? nullptr : make_unique<std::vector<ASTPointer<Expression>>>(arguments)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
@ -381,14 +381,14 @@ void ElementaryTypeName::accept(ASTConstVisitor& _visitor) const
|
|||||||
void UserDefinedTypeName::accept(ASTVisitor& _visitor)
|
void UserDefinedTypeName::accept(ASTVisitor& _visitor)
|
||||||
{
|
{
|
||||||
if (_visitor.visit(*this))
|
if (_visitor.visit(*this))
|
||||||
this->pathNode()->accept(_visitor);
|
this->pathNode().accept(_visitor);
|
||||||
_visitor.endVisit(*this);
|
_visitor.endVisit(*this);
|
||||||
}
|
}
|
||||||
|
|
||||||
void UserDefinedTypeName::accept(ASTConstVisitor& _visitor) const
|
void UserDefinedTypeName::accept(ASTConstVisitor& _visitor) const
|
||||||
{
|
{
|
||||||
if (_visitor.visit(*this))
|
if (_visitor.visit(*this))
|
||||||
this->pathNode()->accept(_visitor);
|
this->pathNode().accept(_visitor);
|
||||||
_visitor.endVisit(*this);
|
_visitor.endVisit(*this);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1293,14 +1293,14 @@ void ContractCompiler::appendModifierOrFunctionCode()
|
|||||||
ASTPointer<ModifierInvocation> const& modifierInvocation = m_currentFunction->modifiers()[m_modifierDepth];
|
ASTPointer<ModifierInvocation> const& modifierInvocation = m_currentFunction->modifiers()[m_modifierDepth];
|
||||||
|
|
||||||
// constructor call should be excluded
|
// constructor call should be excluded
|
||||||
if (dynamic_cast<ContractDefinition const*>(modifierInvocation->name()->annotation().referencedDeclaration))
|
if (dynamic_cast<ContractDefinition const*>(modifierInvocation->name().annotation().referencedDeclaration))
|
||||||
appendModifierOrFunctionCode();
|
appendModifierOrFunctionCode();
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
solAssert(*modifierInvocation->name()->annotation().requiredLookup == VirtualLookup::Virtual, "");
|
solAssert(*modifierInvocation->name().annotation().requiredLookup == VirtualLookup::Virtual, "");
|
||||||
|
|
||||||
ModifierDefinition const& modifier = dynamic_cast<ModifierDefinition const&>(
|
ModifierDefinition const& modifier = dynamic_cast<ModifierDefinition const&>(
|
||||||
*modifierInvocation->name()->annotation().referencedDeclaration
|
*modifierInvocation->name().annotation().referencedDeclaration
|
||||||
).resolveVirtual(m_context.mostDerivedContract());
|
).resolveVirtual(m_context.mostDerivedContract());
|
||||||
CompilerContext::LocationSetter locationSetter(m_context, modifier);
|
CompilerContext::LocationSetter locationSetter(m_context, modifier);
|
||||||
std::vector<ASTPointer<Expression>> const& modifierArguments =
|
std::vector<ASTPointer<Expression>> const& modifierArguments =
|
||||||
|
@ -444,7 +444,7 @@ pair<string, map<ContractDefinition const*, vector<string>>> IRGenerator::evalua
|
|||||||
if (FunctionDefinition const* constructor = _contract.constructor())
|
if (FunctionDefinition const* constructor = _contract.constructor())
|
||||||
for (ASTPointer<ModifierInvocation> const& modifier: constructor->modifiers())
|
for (ASTPointer<ModifierInvocation> const& modifier: constructor->modifiers())
|
||||||
if (auto const* baseContract = dynamic_cast<ContractDefinition const*>(
|
if (auto const* baseContract = dynamic_cast<ContractDefinition const*>(
|
||||||
modifier->name()->annotation().referencedDeclaration
|
modifier->name().annotation().referencedDeclaration
|
||||||
))
|
))
|
||||||
if (
|
if (
|
||||||
FunctionDefinition const* baseConstructor = baseContract->constructor();
|
FunctionDefinition const* baseConstructor = baseContract->constructor();
|
||||||
|
@ -58,7 +58,7 @@ bool SMTEncoder::visit(ContractDefinition const& _contract)
|
|||||||
if (auto const& constructor = base->constructor())
|
if (auto const& constructor = base->constructor())
|
||||||
for (auto const& invocation: constructor->modifiers())
|
for (auto const& invocation: constructor->modifiers())
|
||||||
{
|
{
|
||||||
auto refDecl = invocation->name()->annotation().referencedDeclaration;
|
auto refDecl = invocation->name().annotation().referencedDeclaration;
|
||||||
if (auto const& baseContract = dynamic_cast<ContractDefinition const*>(refDecl))
|
if (auto const& baseContract = dynamic_cast<ContractDefinition const*>(refDecl))
|
||||||
{
|
{
|
||||||
solAssert(!m_baseConstructorCalls.count(baseContract), "");
|
solAssert(!m_baseConstructorCalls.count(baseContract), "");
|
||||||
@ -164,7 +164,7 @@ void SMTEncoder::visitFunctionOrModifier()
|
|||||||
ASTPointer<ModifierInvocation> const& modifierInvocation =
|
ASTPointer<ModifierInvocation> const& modifierInvocation =
|
||||||
function.modifiers()[static_cast<size_t>(m_modifierDepthStack.back())];
|
function.modifiers()[static_cast<size_t>(m_modifierDepthStack.back())];
|
||||||
solAssert(modifierInvocation, "");
|
solAssert(modifierInvocation, "");
|
||||||
auto refDecl = modifierInvocation->name()->annotation().referencedDeclaration;
|
auto refDecl = modifierInvocation->name().annotation().referencedDeclaration;
|
||||||
if (dynamic_cast<ContractDefinition const*>(refDecl))
|
if (dynamic_cast<ContractDefinition const*>(refDecl))
|
||||||
visitFunctionOrModifier();
|
visitFunctionOrModifier();
|
||||||
else if (auto modifierDef = dynamic_cast<ModifierDefinition const*>(refDecl))
|
else if (auto modifierDef = dynamic_cast<ModifierDefinition const*>(refDecl))
|
||||||
|
@ -83,7 +83,7 @@ void VariableUsage::endVisit(FunctionDefinition const&)
|
|||||||
|
|
||||||
void VariableUsage::endVisit(ModifierInvocation const& _modifierInv)
|
void VariableUsage::endVisit(ModifierInvocation const& _modifierInv)
|
||||||
{
|
{
|
||||||
auto const& modifierDef = dynamic_cast<ModifierDefinition const*>(_modifierInv.name()->annotation().referencedDeclaration);
|
auto const& modifierDef = dynamic_cast<ModifierDefinition const*>(_modifierInv.name().annotation().referencedDeclaration);
|
||||||
if (modifierDef)
|
if (modifierDef)
|
||||||
modifierDef->accept(*this);
|
modifierDef->accept(*this);
|
||||||
}
|
}
|
||||||
|
@ -389,7 +389,7 @@ ASTPointer<InheritanceSpecifier> Parser::parseInheritanceSpecifier()
|
|||||||
{
|
{
|
||||||
RecursionGuard recursionGuard(*this);
|
RecursionGuard recursionGuard(*this);
|
||||||
ASTNodeFactory nodeFactory(*this);
|
ASTNodeFactory nodeFactory(*this);
|
||||||
ASTPointer<UserDefinedTypeName> name(parseUserDefinedTypeName());
|
ASTPointer<IdentifierPath> name(parseIdentifierPath());
|
||||||
unique_ptr<vector<ASTPointer<Expression>>> arguments;
|
unique_ptr<vector<ASTPointer<Expression>>> arguments;
|
||||||
if (m_scanner->currentToken() == Token::LParen)
|
if (m_scanner->currentToken() == Token::LParen)
|
||||||
{
|
{
|
||||||
@ -433,7 +433,7 @@ ASTPointer<OverrideSpecifier> Parser::parseOverrideSpecifier()
|
|||||||
solAssert(m_scanner->currentToken() == Token::Override, "");
|
solAssert(m_scanner->currentToken() == Token::Override, "");
|
||||||
|
|
||||||
ASTNodeFactory nodeFactory(*this);
|
ASTNodeFactory nodeFactory(*this);
|
||||||
std::vector<ASTPointer<UserDefinedTypeName>> overrides;
|
std::vector<ASTPointer<IdentifierPath>> overrides;
|
||||||
|
|
||||||
nodeFactory.markEndPosition();
|
nodeFactory.markEndPosition();
|
||||||
m_scanner->next();
|
m_scanner->next();
|
||||||
@ -443,7 +443,7 @@ ASTPointer<OverrideSpecifier> Parser::parseOverrideSpecifier()
|
|||||||
m_scanner->next();
|
m_scanner->next();
|
||||||
while (true)
|
while (true)
|
||||||
{
|
{
|
||||||
overrides.push_back(parseUserDefinedTypeName());
|
overrides.push_back(parseIdentifierPath());
|
||||||
|
|
||||||
if (m_scanner->currentToken() == Token::RParen)
|
if (m_scanner->currentToken() == Token::RParen)
|
||||||
break;
|
break;
|
||||||
@ -900,7 +900,7 @@ ASTPointer<UsingForDirective> Parser::parseUsingDirective()
|
|||||||
ASTNodeFactory nodeFactory(*this);
|
ASTNodeFactory nodeFactory(*this);
|
||||||
|
|
||||||
expectToken(Token::Using);
|
expectToken(Token::Using);
|
||||||
ASTPointer<UserDefinedTypeName> library(parseUserDefinedTypeName());
|
ASTPointer<IdentifierPath> library(parseIdentifierPath());
|
||||||
ASTPointer<TypeName> typeName;
|
ASTPointer<TypeName> typeName;
|
||||||
expectToken(Token::For);
|
expectToken(Token::For);
|
||||||
if (m_scanner->currentToken() == Token::Mul)
|
if (m_scanner->currentToken() == Token::Mul)
|
||||||
@ -916,7 +916,7 @@ ASTPointer<ModifierInvocation> Parser::parseModifierInvocation()
|
|||||||
{
|
{
|
||||||
RecursionGuard recursionGuard(*this);
|
RecursionGuard recursionGuard(*this);
|
||||||
ASTNodeFactory nodeFactory(*this);
|
ASTNodeFactory nodeFactory(*this);
|
||||||
ASTPointer<Identifier> name(parseIdentifier());
|
ASTPointer<IdentifierPath> name(parseIdentifierPath());
|
||||||
unique_ptr<vector<ASTPointer<Expression>>> arguments;
|
unique_ptr<vector<ASTPointer<Expression>>> arguments;
|
||||||
if (m_scanner->currentToken() == Token::LParen)
|
if (m_scanner->currentToken() == Token::LParen)
|
||||||
{
|
{
|
||||||
|
@ -34,17 +34,17 @@ Optimized IR:
|
|||||||
* !USE AT YOUR OWN RISK! *
|
* !USE AT YOUR OWN RISK! *
|
||||||
*******************************************************/
|
*******************************************************/
|
||||||
|
|
||||||
object "D_10" {
|
object "D_9" {
|
||||||
code {
|
code {
|
||||||
{
|
{
|
||||||
mstore(64, memoryguard(0x80))
|
mstore(64, memoryguard(0x80))
|
||||||
if callvalue() { revert(0, 0) }
|
if callvalue() { revert(0, 0) }
|
||||||
let _1 := datasize("D_10_deployed")
|
let _1 := datasize("D_9_deployed")
|
||||||
codecopy(0, dataoffset("D_10_deployed"), _1)
|
codecopy(0, dataoffset("D_9_deployed"), _1)
|
||||||
return(0, _1)
|
return(0, _1)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
object "D_10_deployed" {
|
object "D_9_deployed" {
|
||||||
code {
|
code {
|
||||||
{
|
{
|
||||||
mstore(64, memoryguard(0x80))
|
mstore(64, memoryguard(0x80))
|
||||||
|
@ -6,17 +6,17 @@ Optimized IR:
|
|||||||
* !USE AT YOUR OWN RISK! *
|
* !USE AT YOUR OWN RISK! *
|
||||||
*******************************************************/
|
*******************************************************/
|
||||||
|
|
||||||
object "C_56" {
|
object "C_59" {
|
||||||
code {
|
code {
|
||||||
{
|
{
|
||||||
mstore(64, memoryguard(0x80))
|
mstore(64, memoryguard(0x80))
|
||||||
if callvalue() { revert(0, 0) }
|
if callvalue() { revert(0, 0) }
|
||||||
let _1 := datasize("C_56_deployed")
|
let _1 := datasize("C_59_deployed")
|
||||||
codecopy(0, dataoffset("C_56_deployed"), _1)
|
codecopy(0, dataoffset("C_59_deployed"), _1)
|
||||||
return(0, _1)
|
return(0, _1)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
object "C_56_deployed" {
|
object "C_59_deployed" {
|
||||||
code {
|
code {
|
||||||
{
|
{
|
||||||
mstore(64, memoryguard(0x80))
|
mstore(64, memoryguard(0x80))
|
||||||
@ -48,7 +48,7 @@ object "C_56" {
|
|||||||
dst := add(dst, _2)
|
dst := add(dst, _2)
|
||||||
src := add(src, _2)
|
src := add(src, _2)
|
||||||
}
|
}
|
||||||
let ret, ret_1 := fun_sumArray_55(dst_1)
|
let ret, ret_1 := fun_sumArray_58(dst_1)
|
||||||
let memPos := allocateMemory(_1)
|
let memPos := allocateMemory(_1)
|
||||||
return(memPos, sub(abi_encode_uint256_t_string(memPos, ret, ret_1), memPos))
|
return(memPos, sub(abi_encode_uint256_t_string(memPos, ret, ret_1), memPos))
|
||||||
}
|
}
|
||||||
@ -107,15 +107,15 @@ object "C_56" {
|
|||||||
{
|
{
|
||||||
value := shr(mul(offset, 8), slot_value)
|
value := shr(mul(offset, 8), slot_value)
|
||||||
}
|
}
|
||||||
function fun_sumArray_55(vloc__s_19_mpos) -> vloc, vloc__24_mpos
|
function fun_sumArray_58(vloc__s_22_mpos) -> vloc, vloc__27_mpos
|
||||||
{
|
{
|
||||||
let _1 := mload(vloc__s_19_mpos)
|
let _1 := mload(vloc__s_22_mpos)
|
||||||
if iszero(lt(vloc, _1)) { invalid() }
|
if iszero(lt(vloc, _1)) { invalid() }
|
||||||
let _2 := mload(mload(add(add(vloc__s_19_mpos, mul(vloc, 32)), 32)))
|
let _2 := mload(mload(add(add(vloc__s_22_mpos, mul(vloc, 32)), 32)))
|
||||||
let _3, _4 := storage_array_index_access$_t_struct$_S_storage(vloc, vloc)
|
let _3, _4 := storage_array_index_access$_t_struct$_S_storage(vloc, vloc)
|
||||||
sstore(_3, _2)
|
sstore(_3, _2)
|
||||||
if iszero(lt(0x01, _1)) { invalid() }
|
if iszero(lt(0x01, _1)) { invalid() }
|
||||||
let _5 := mload(mload(add(vloc__s_19_mpos, 64)))
|
let _5 := mload(mload(add(vloc__s_22_mpos, 64)))
|
||||||
if iszero(lt(vloc, 0x02)) { invalid() }
|
if iszero(lt(vloc, 0x02)) { invalid() }
|
||||||
let slot := add(0x02, vloc)
|
let slot := add(0x02, vloc)
|
||||||
let _6 := sload(slot)
|
let _6 := sload(slot)
|
||||||
@ -124,7 +124,7 @@ object "C_56" {
|
|||||||
sstore(slot, or(and(_6, not(mask)), and(shl(shiftBits, _5), mask)))
|
sstore(slot, or(and(_6, not(mask)), and(shl(shiftBits, _5), mask)))
|
||||||
let _7, _8 := storage_array_index_access$_t_struct$_S_storage(0x02, vloc)
|
let _7, _8 := storage_array_index_access$_t_struct$_S_storage(0x02, vloc)
|
||||||
vloc := extract_from_storage_value_dynamict_uint256(sload(_7), _8)
|
vloc := extract_from_storage_value_dynamict_uint256(sload(_7), _8)
|
||||||
vloc__24_mpos := convert_t_stringliteral_6490_to_t_string()
|
vloc__27_mpos := convert_t_stringliteral_6490_to_t_string()
|
||||||
}
|
}
|
||||||
function storage_array_index_access$_t_struct$_S_storage(array, index) -> slot, offset
|
function storage_array_index_access$_t_struct$_S_storage(array, index) -> slot, offset
|
||||||
{
|
{
|
||||||
|
@ -4,4 +4,4 @@ pragma solidity >=0.0; contract Errort6 { using foo for ; /* missing type name
|
|||||||
","message":"Expected type name","severity":"error","sourceLocation":{"end":94,"file":"A","start":93},"type":"ParserError"},{"component":"general","errorCode":"3796","formattedMessage":"A:2:84: Warning: Recovered in ContractDefinition at '}'.
|
","message":"Expected type name","severity":"error","sourceLocation":{"end":94,"file":"A","start":93},"type":"ParserError"},{"component":"general","errorCode":"3796","formattedMessage":"A:2:84: Warning: Recovered in ContractDefinition at '}'.
|
||||||
pragma solidity >=0.0; contract Errort6 { using foo for ; /* missing type name */ }
|
pragma solidity >=0.0; contract Errort6 { using foo for ; /* missing type name */ }
|
||||||
^
|
^
|
||||||
","message":"Recovered in ContractDefinition at '}'.","severity":"warning","sourceLocation":{"end":120,"file":"A","start":119},"type":"Warning"}],"sources":{"A":{"ast":{"absolutePath":"A","exportedSymbols":{"Errort6":[4]},"id":5,"license":"GPL-3.0","nodeType":"SourceUnit","nodes":[{"id":1,"literals":["solidity",">=","0.0"],"nodeType":"PragmaDirective","src":"36:22:0"},{"abstract":false,"baseContracts":[],"contractDependencies":[],"contractKind":"contract","fullyImplemented":true,"id":4,"linearizedBaseContracts":[4],"name":"Errort6","nodeType":"ContractDefinition","nodes":[],"scope":5,"src":"59:35:0"}],"src":"36:84:0"},"id":0}}}
|
","message":"Recovered in ContractDefinition at '}'.","severity":"warning","sourceLocation":{"end":120,"file":"A","start":119},"type":"Warning"}],"sources":{"A":{"ast":{"absolutePath":"A","exportedSymbols":{"Errort6":[3]},"id":4,"license":"GPL-3.0","nodeType":"SourceUnit","nodes":[{"id":1,"literals":["solidity",">=","0.0"],"nodeType":"PragmaDirective","src":"36:22:0"},{"abstract":false,"baseContracts":[],"contractDependencies":[],"contractKind":"contract","fullyImplemented":true,"id":3,"linearizedBaseContracts":[3],"name":"Errort6","nodeType":"ContractDefinition","nodes":[],"scope":4,"src":"59:35:0"}],"src":"36:84:0"},"id":0}}}
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"absolutePath": "a",
|
"absolutePath": "a",
|
||||||
"id": 12,
|
"id": 13,
|
||||||
"nodeType": "SourceUnit",
|
"nodeType": "SourceUnit",
|
||||||
"nodes":
|
"nodes":
|
||||||
[
|
[
|
||||||
@ -9,7 +9,7 @@
|
|||||||
"baseContracts": [],
|
"baseContracts": [],
|
||||||
"contractDependencies": [],
|
"contractDependencies": [],
|
||||||
"contractKind": "contract",
|
"contractKind": "contract",
|
||||||
"id": 11,
|
"id": 12,
|
||||||
"name": "C",
|
"name": "C",
|
||||||
"nodeType": "ContractDefinition",
|
"nodeType": "ContractDefinition",
|
||||||
"nodes":
|
"nodes":
|
||||||
@ -46,7 +46,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"constant": false,
|
"constant": false,
|
||||||
"id": 5,
|
"id": 6,
|
||||||
"mutability": "mutable",
|
"mutability": "mutable",
|
||||||
"name": "s",
|
"name": "s",
|
||||||
"nodeType": "VariableDeclaration",
|
"nodeType": "VariableDeclaration",
|
||||||
@ -56,9 +56,15 @@
|
|||||||
"typeDescriptions": {},
|
"typeDescriptions": {},
|
||||||
"typeName":
|
"typeName":
|
||||||
{
|
{
|
||||||
"id": 4,
|
"id": 5,
|
||||||
"name": "S",
|
|
||||||
"nodeType": "UserDefinedTypeName",
|
"nodeType": "UserDefinedTypeName",
|
||||||
|
"pathNode":
|
||||||
|
{
|
||||||
|
"id": 4,
|
||||||
|
"name": "S",
|
||||||
|
"nodeType": "IdentifierPath",
|
||||||
|
"src": "42:1:1"
|
||||||
|
},
|
||||||
"src": "42:1:1",
|
"src": "42:1:1",
|
||||||
"typeDescriptions": {}
|
"typeDescriptions": {}
|
||||||
},
|
},
|
||||||
@ -67,7 +73,7 @@
|
|||||||
{
|
{
|
||||||
"body":
|
"body":
|
||||||
{
|
{
|
||||||
"id": 9,
|
"id": 10,
|
||||||
"nodeType": "Block",
|
"nodeType": "Block",
|
||||||
"src": "76:70:1",
|
"src": "76:70:1",
|
||||||
"statements":
|
"statements":
|
||||||
@ -141,13 +147,13 @@
|
|||||||
},
|
},
|
||||||
"evmVersion": %EVMVERSION%,
|
"evmVersion": %EVMVERSION%,
|
||||||
"externalReferences": [],
|
"externalReferences": [],
|
||||||
"id": 8,
|
"id": 9,
|
||||||
"nodeType": "InlineAssembly",
|
"nodeType": "InlineAssembly",
|
||||||
"src": "86:54:1"
|
"src": "86:54:1"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"id": 10,
|
"id": 11,
|
||||||
"implemented": true,
|
"implemented": true,
|
||||||
"kind": "function",
|
"kind": "function",
|
||||||
"modifiers": [],
|
"modifiers": [],
|
||||||
@ -155,14 +161,14 @@
|
|||||||
"nodeType": "FunctionDefinition",
|
"nodeType": "FunctionDefinition",
|
||||||
"parameters":
|
"parameters":
|
||||||
{
|
{
|
||||||
"id": 6,
|
"id": 7,
|
||||||
"nodeType": "ParameterList",
|
"nodeType": "ParameterList",
|
||||||
"parameters": [],
|
"parameters": [],
|
||||||
"src": "61:2:1"
|
"src": "61:2:1"
|
||||||
},
|
},
|
||||||
"returnParameters":
|
"returnParameters":
|
||||||
{
|
{
|
||||||
"id": 7,
|
"id": 8,
|
||||||
"nodeType": "ParameterList",
|
"nodeType": "ParameterList",
|
||||||
"parameters": [],
|
"parameters": [],
|
||||||
"src": "76:0:1"
|
"src": "76:0:1"
|
||||||
|
@ -8,22 +8,22 @@
|
|||||||
],
|
],
|
||||||
"B":
|
"B":
|
||||||
[
|
[
|
||||||
5
|
4
|
||||||
],
|
],
|
||||||
"C":
|
"C":
|
||||||
[
|
[
|
||||||
9
|
7
|
||||||
],
|
],
|
||||||
"D":
|
"D":
|
||||||
[
|
[
|
||||||
13
|
10
|
||||||
],
|
],
|
||||||
"E":
|
"E":
|
||||||
[
|
[
|
||||||
17
|
13
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"id": 18,
|
"id": 14,
|
||||||
"nodeType": "SourceUnit",
|
"nodeType": "SourceUnit",
|
||||||
"nodes":
|
"nodes":
|
||||||
[
|
[
|
||||||
@ -41,7 +41,7 @@
|
|||||||
"name": "A",
|
"name": "A",
|
||||||
"nodeType": "ContractDefinition",
|
"nodeType": "ContractDefinition",
|
||||||
"nodes": [],
|
"nodes": [],
|
||||||
"scope": 18,
|
"scope": 14,
|
||||||
"src": "0:14:1"
|
"src": "0:14:1"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -51,25 +51,13 @@
|
|||||||
{
|
{
|
||||||
"baseName":
|
"baseName":
|
||||||
{
|
{
|
||||||
"id": 3,
|
"id": 2,
|
||||||
"nodeType": "UserDefinedTypeName",
|
"name": "A",
|
||||||
"pathNode":
|
"nodeType": "IdentifierPath",
|
||||||
{
|
|
||||||
"id": 2,
|
|
||||||
"name": "A",
|
|
||||||
"nodeType": "IdentifierPath",
|
|
||||||
"referencedDeclaration": 1,
|
|
||||||
"src": "29:1:1"
|
|
||||||
},
|
|
||||||
"referencedDeclaration": 1,
|
"referencedDeclaration": 1,
|
||||||
"src": "29:1:1",
|
"src": "29:1:1"
|
||||||
"typeDescriptions":
|
|
||||||
{
|
|
||||||
"typeIdentifier": "t_contract$_A_$1",
|
|
||||||
"typeString": "contract A"
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
"id": 4,
|
"id": 3,
|
||||||
"nodeType": "InheritanceSpecifier",
|
"nodeType": "InheritanceSpecifier",
|
||||||
"src": "29:1:1"
|
"src": "29:1:1"
|
||||||
}
|
}
|
||||||
@ -80,16 +68,16 @@
|
|||||||
],
|
],
|
||||||
"contractKind": "contract",
|
"contractKind": "contract",
|
||||||
"fullyImplemented": true,
|
"fullyImplemented": true,
|
||||||
"id": 5,
|
"id": 4,
|
||||||
"linearizedBaseContracts":
|
"linearizedBaseContracts":
|
||||||
[
|
[
|
||||||
5,
|
4,
|
||||||
1
|
1
|
||||||
],
|
],
|
||||||
"name": "B",
|
"name": "B",
|
||||||
"nodeType": "ContractDefinition",
|
"nodeType": "ContractDefinition",
|
||||||
"nodes": [],
|
"nodes": [],
|
||||||
"scope": 18,
|
"scope": 14,
|
||||||
"src": "15:19:1"
|
"src": "15:19:1"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -99,25 +87,13 @@
|
|||||||
{
|
{
|
||||||
"baseName":
|
"baseName":
|
||||||
{
|
{
|
||||||
"id": 7,
|
"id": 5,
|
||||||
"nodeType": "UserDefinedTypeName",
|
"name": "B",
|
||||||
"pathNode":
|
"nodeType": "IdentifierPath",
|
||||||
{
|
"referencedDeclaration": 4,
|
||||||
"id": 6,
|
"src": "49:1:1"
|
||||||
"name": "B",
|
|
||||||
"nodeType": "IdentifierPath",
|
|
||||||
"referencedDeclaration": 5,
|
|
||||||
"src": "49:1:1"
|
|
||||||
},
|
|
||||||
"referencedDeclaration": 5,
|
|
||||||
"src": "49:1:1",
|
|
||||||
"typeDescriptions":
|
|
||||||
{
|
|
||||||
"typeIdentifier": "t_contract$_B_$5",
|
|
||||||
"typeString": "contract B"
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
"id": 8,
|
"id": 6,
|
||||||
"nodeType": "InheritanceSpecifier",
|
"nodeType": "InheritanceSpecifier",
|
||||||
"src": "49:1:1"
|
"src": "49:1:1"
|
||||||
}
|
}
|
||||||
@ -125,21 +101,21 @@
|
|||||||
"contractDependencies":
|
"contractDependencies":
|
||||||
[
|
[
|
||||||
1,
|
1,
|
||||||
5
|
4
|
||||||
],
|
],
|
||||||
"contractKind": "contract",
|
"contractKind": "contract",
|
||||||
"fullyImplemented": true,
|
"fullyImplemented": true,
|
||||||
"id": 9,
|
"id": 7,
|
||||||
"linearizedBaseContracts":
|
"linearizedBaseContracts":
|
||||||
[
|
[
|
||||||
9,
|
7,
|
||||||
5,
|
4,
|
||||||
1
|
1
|
||||||
],
|
],
|
||||||
"name": "C",
|
"name": "C",
|
||||||
"nodeType": "ContractDefinition",
|
"nodeType": "ContractDefinition",
|
||||||
"nodes": [],
|
"nodes": [],
|
||||||
"scope": 18,
|
"scope": 14,
|
||||||
"src": "35:19:1"
|
"src": "35:19:1"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -149,25 +125,13 @@
|
|||||||
{
|
{
|
||||||
"baseName":
|
"baseName":
|
||||||
{
|
{
|
||||||
"id": 11,
|
"id": 8,
|
||||||
"nodeType": "UserDefinedTypeName",
|
"name": "C",
|
||||||
"pathNode":
|
"nodeType": "IdentifierPath",
|
||||||
{
|
"referencedDeclaration": 7,
|
||||||
"id": 10,
|
"src": "69:1:1"
|
||||||
"name": "C",
|
|
||||||
"nodeType": "IdentifierPath",
|
|
||||||
"referencedDeclaration": 9,
|
|
||||||
"src": "69:1:1"
|
|
||||||
},
|
|
||||||
"referencedDeclaration": 9,
|
|
||||||
"src": "69:1:1",
|
|
||||||
"typeDescriptions":
|
|
||||||
{
|
|
||||||
"typeIdentifier": "t_contract$_C_$9",
|
|
||||||
"typeString": "contract C"
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
"id": 12,
|
"id": 9,
|
||||||
"nodeType": "InheritanceSpecifier",
|
"nodeType": "InheritanceSpecifier",
|
||||||
"src": "69:1:1"
|
"src": "69:1:1"
|
||||||
}
|
}
|
||||||
@ -175,23 +139,23 @@
|
|||||||
"contractDependencies":
|
"contractDependencies":
|
||||||
[
|
[
|
||||||
1,
|
1,
|
||||||
5,
|
4,
|
||||||
9
|
7
|
||||||
],
|
],
|
||||||
"contractKind": "contract",
|
"contractKind": "contract",
|
||||||
"fullyImplemented": true,
|
"fullyImplemented": true,
|
||||||
"id": 13,
|
"id": 10,
|
||||||
"linearizedBaseContracts":
|
"linearizedBaseContracts":
|
||||||
[
|
[
|
||||||
13,
|
10,
|
||||||
9,
|
7,
|
||||||
5,
|
4,
|
||||||
1
|
1
|
||||||
],
|
],
|
||||||
"name": "D",
|
"name": "D",
|
||||||
"nodeType": "ContractDefinition",
|
"nodeType": "ContractDefinition",
|
||||||
"nodes": [],
|
"nodes": [],
|
||||||
"scope": 18,
|
"scope": 14,
|
||||||
"src": "55:19:1"
|
"src": "55:19:1"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -201,25 +165,13 @@
|
|||||||
{
|
{
|
||||||
"baseName":
|
"baseName":
|
||||||
{
|
{
|
||||||
"id": 15,
|
"id": 11,
|
||||||
"nodeType": "UserDefinedTypeName",
|
"name": "D",
|
||||||
"pathNode":
|
"nodeType": "IdentifierPath",
|
||||||
{
|
"referencedDeclaration": 10,
|
||||||
"id": 14,
|
"src": "89:1:1"
|
||||||
"name": "D",
|
|
||||||
"nodeType": "IdentifierPath",
|
|
||||||
"referencedDeclaration": 13,
|
|
||||||
"src": "89:1:1"
|
|
||||||
},
|
|
||||||
"referencedDeclaration": 13,
|
|
||||||
"src": "89:1:1",
|
|
||||||
"typeDescriptions":
|
|
||||||
{
|
|
||||||
"typeIdentifier": "t_contract$_D_$13",
|
|
||||||
"typeString": "contract D"
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
"id": 16,
|
"id": 12,
|
||||||
"nodeType": "InheritanceSpecifier",
|
"nodeType": "InheritanceSpecifier",
|
||||||
"src": "89:1:1"
|
"src": "89:1:1"
|
||||||
}
|
}
|
||||||
@ -227,25 +179,25 @@
|
|||||||
"contractDependencies":
|
"contractDependencies":
|
||||||
[
|
[
|
||||||
1,
|
1,
|
||||||
5,
|
4,
|
||||||
9,
|
7,
|
||||||
13
|
10
|
||||||
],
|
],
|
||||||
"contractKind": "contract",
|
"contractKind": "contract",
|
||||||
"fullyImplemented": true,
|
"fullyImplemented": true,
|
||||||
"id": 17,
|
"id": 13,
|
||||||
"linearizedBaseContracts":
|
"linearizedBaseContracts":
|
||||||
[
|
[
|
||||||
17,
|
|
||||||
13,
|
13,
|
||||||
9,
|
10,
|
||||||
5,
|
7,
|
||||||
|
4,
|
||||||
1
|
1
|
||||||
],
|
],
|
||||||
"name": "E",
|
"name": "E",
|
||||||
"nodeType": "ContractDefinition",
|
"nodeType": "ContractDefinition",
|
||||||
"nodes": [],
|
"nodes": [],
|
||||||
"scope": 18,
|
"scope": 14,
|
||||||
"src": "75:19:1"
|
"src": "75:19:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
@ -10,19 +10,19 @@
|
|||||||
],
|
],
|
||||||
"B":
|
"B":
|
||||||
[
|
[
|
||||||
5
|
4
|
||||||
],
|
],
|
||||||
"C":
|
"C":
|
||||||
[
|
[
|
||||||
9
|
7
|
||||||
],
|
],
|
||||||
"D":
|
"D":
|
||||||
[
|
[
|
||||||
13
|
10
|
||||||
],
|
],
|
||||||
"E":
|
"E":
|
||||||
[
|
[
|
||||||
17
|
13
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@ -51,7 +51,7 @@
|
|||||||
[
|
[
|
||||||
null
|
null
|
||||||
],
|
],
|
||||||
"scope": 18
|
"scope": 14
|
||||||
},
|
},
|
||||||
"id": 1,
|
"id": 1,
|
||||||
"name": "ContractDefinition",
|
"name": "ContractDefinition",
|
||||||
@ -69,7 +69,7 @@
|
|||||||
"fullyImplemented": true,
|
"fullyImplemented": true,
|
||||||
"linearizedBaseContracts":
|
"linearizedBaseContracts":
|
||||||
[
|
[
|
||||||
5,
|
4,
|
||||||
1
|
1
|
||||||
],
|
],
|
||||||
"name": "B",
|
"name": "B",
|
||||||
@ -77,7 +77,7 @@
|
|||||||
[
|
[
|
||||||
null
|
null
|
||||||
],
|
],
|
||||||
"scope": 18
|
"scope": 14
|
||||||
},
|
},
|
||||||
"children":
|
"children":
|
||||||
[
|
[
|
||||||
@ -88,33 +88,20 @@
|
|||||||
{
|
{
|
||||||
"attributes":
|
"attributes":
|
||||||
{
|
{
|
||||||
"referencedDeclaration": 1,
|
"name": "A",
|
||||||
"type": "contract A"
|
"referencedDeclaration": 1
|
||||||
},
|
},
|
||||||
"children":
|
"id": 2,
|
||||||
[
|
"name": "IdentifierPath",
|
||||||
{
|
|
||||||
"attributes":
|
|
||||||
{
|
|
||||||
"name": "A",
|
|
||||||
"referencedDeclaration": 1
|
|
||||||
},
|
|
||||||
"id": 2,
|
|
||||||
"name": "IdentifierPath",
|
|
||||||
"src": "29:1:1"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"id": 3,
|
|
||||||
"name": "UserDefinedTypeName",
|
|
||||||
"src": "29:1:1"
|
"src": "29:1:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 4,
|
"id": 3,
|
||||||
"name": "InheritanceSpecifier",
|
"name": "InheritanceSpecifier",
|
||||||
"src": "29:1:1"
|
"src": "29:1:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 5,
|
"id": 4,
|
||||||
"name": "ContractDefinition",
|
"name": "ContractDefinition",
|
||||||
"src": "15:19:1"
|
"src": "15:19:1"
|
||||||
},
|
},
|
||||||
@ -125,14 +112,14 @@
|
|||||||
"contractDependencies":
|
"contractDependencies":
|
||||||
[
|
[
|
||||||
1,
|
1,
|
||||||
5
|
4
|
||||||
],
|
],
|
||||||
"contractKind": "contract",
|
"contractKind": "contract",
|
||||||
"fullyImplemented": true,
|
"fullyImplemented": true,
|
||||||
"linearizedBaseContracts":
|
"linearizedBaseContracts":
|
||||||
[
|
[
|
||||||
9,
|
7,
|
||||||
5,
|
4,
|
||||||
1
|
1
|
||||||
],
|
],
|
||||||
"name": "C",
|
"name": "C",
|
||||||
@ -140,7 +127,7 @@
|
|||||||
[
|
[
|
||||||
null
|
null
|
||||||
],
|
],
|
||||||
"scope": 18
|
"scope": 14
|
||||||
},
|
},
|
||||||
"children":
|
"children":
|
||||||
[
|
[
|
||||||
@ -151,33 +138,20 @@
|
|||||||
{
|
{
|
||||||
"attributes":
|
"attributes":
|
||||||
{
|
{
|
||||||
"referencedDeclaration": 5,
|
"name": "B",
|
||||||
"type": "contract B"
|
"referencedDeclaration": 4
|
||||||
},
|
},
|
||||||
"children":
|
"id": 5,
|
||||||
[
|
"name": "IdentifierPath",
|
||||||
{
|
|
||||||
"attributes":
|
|
||||||
{
|
|
||||||
"name": "B",
|
|
||||||
"referencedDeclaration": 5
|
|
||||||
},
|
|
||||||
"id": 6,
|
|
||||||
"name": "IdentifierPath",
|
|
||||||
"src": "49:1:1"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"id": 7,
|
|
||||||
"name": "UserDefinedTypeName",
|
|
||||||
"src": "49:1:1"
|
"src": "49:1:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 8,
|
"id": 6,
|
||||||
"name": "InheritanceSpecifier",
|
"name": "InheritanceSpecifier",
|
||||||
"src": "49:1:1"
|
"src": "49:1:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 9,
|
"id": 7,
|
||||||
"name": "ContractDefinition",
|
"name": "ContractDefinition",
|
||||||
"src": "35:19:1"
|
"src": "35:19:1"
|
||||||
},
|
},
|
||||||
@ -188,16 +162,16 @@
|
|||||||
"contractDependencies":
|
"contractDependencies":
|
||||||
[
|
[
|
||||||
1,
|
1,
|
||||||
5,
|
4,
|
||||||
9
|
7
|
||||||
],
|
],
|
||||||
"contractKind": "contract",
|
"contractKind": "contract",
|
||||||
"fullyImplemented": true,
|
"fullyImplemented": true,
|
||||||
"linearizedBaseContracts":
|
"linearizedBaseContracts":
|
||||||
[
|
[
|
||||||
13,
|
10,
|
||||||
9,
|
7,
|
||||||
5,
|
4,
|
||||||
1
|
1
|
||||||
],
|
],
|
||||||
"name": "D",
|
"name": "D",
|
||||||
@ -205,7 +179,7 @@
|
|||||||
[
|
[
|
||||||
null
|
null
|
||||||
],
|
],
|
||||||
"scope": 18
|
"scope": 14
|
||||||
},
|
},
|
||||||
"children":
|
"children":
|
||||||
[
|
[
|
||||||
@ -216,33 +190,20 @@
|
|||||||
{
|
{
|
||||||
"attributes":
|
"attributes":
|
||||||
{
|
{
|
||||||
"referencedDeclaration": 9,
|
"name": "C",
|
||||||
"type": "contract C"
|
"referencedDeclaration": 7
|
||||||
},
|
},
|
||||||
"children":
|
"id": 8,
|
||||||
[
|
"name": "IdentifierPath",
|
||||||
{
|
|
||||||
"attributes":
|
|
||||||
{
|
|
||||||
"name": "C",
|
|
||||||
"referencedDeclaration": 9
|
|
||||||
},
|
|
||||||
"id": 10,
|
|
||||||
"name": "IdentifierPath",
|
|
||||||
"src": "69:1:1"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"id": 11,
|
|
||||||
"name": "UserDefinedTypeName",
|
|
||||||
"src": "69:1:1"
|
"src": "69:1:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 12,
|
"id": 9,
|
||||||
"name": "InheritanceSpecifier",
|
"name": "InheritanceSpecifier",
|
||||||
"src": "69:1:1"
|
"src": "69:1:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 13,
|
"id": 10,
|
||||||
"name": "ContractDefinition",
|
"name": "ContractDefinition",
|
||||||
"src": "55:19:1"
|
"src": "55:19:1"
|
||||||
},
|
},
|
||||||
@ -253,18 +214,18 @@
|
|||||||
"contractDependencies":
|
"contractDependencies":
|
||||||
[
|
[
|
||||||
1,
|
1,
|
||||||
5,
|
4,
|
||||||
9,
|
7,
|
||||||
13
|
10
|
||||||
],
|
],
|
||||||
"contractKind": "contract",
|
"contractKind": "contract",
|
||||||
"fullyImplemented": true,
|
"fullyImplemented": true,
|
||||||
"linearizedBaseContracts":
|
"linearizedBaseContracts":
|
||||||
[
|
[
|
||||||
17,
|
|
||||||
13,
|
13,
|
||||||
9,
|
10,
|
||||||
5,
|
7,
|
||||||
|
4,
|
||||||
1
|
1
|
||||||
],
|
],
|
||||||
"name": "E",
|
"name": "E",
|
||||||
@ -272,7 +233,7 @@
|
|||||||
[
|
[
|
||||||
null
|
null
|
||||||
],
|
],
|
||||||
"scope": 18
|
"scope": 14
|
||||||
},
|
},
|
||||||
"children":
|
"children":
|
||||||
[
|
[
|
||||||
@ -283,38 +244,25 @@
|
|||||||
{
|
{
|
||||||
"attributes":
|
"attributes":
|
||||||
{
|
{
|
||||||
"referencedDeclaration": 13,
|
"name": "D",
|
||||||
"type": "contract D"
|
"referencedDeclaration": 10
|
||||||
},
|
},
|
||||||
"children":
|
"id": 11,
|
||||||
[
|
"name": "IdentifierPath",
|
||||||
{
|
|
||||||
"attributes":
|
|
||||||
{
|
|
||||||
"name": "D",
|
|
||||||
"referencedDeclaration": 13
|
|
||||||
},
|
|
||||||
"id": 14,
|
|
||||||
"name": "IdentifierPath",
|
|
||||||
"src": "89:1:1"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"id": 15,
|
|
||||||
"name": "UserDefinedTypeName",
|
|
||||||
"src": "89:1:1"
|
"src": "89:1:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 16,
|
"id": 12,
|
||||||
"name": "InheritanceSpecifier",
|
"name": "InheritanceSpecifier",
|
||||||
"src": "89:1:1"
|
"src": "89:1:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 17,
|
"id": 13,
|
||||||
"name": "ContractDefinition",
|
"name": "ContractDefinition",
|
||||||
"src": "75:19:1"
|
"src": "75:19:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 18,
|
"id": 14,
|
||||||
"name": "SourceUnit",
|
"name": "SourceUnit",
|
||||||
"src": "0:95:1"
|
"src": "0:95:1"
|
||||||
}
|
}
|
||||||
|
@ -24,9 +24,8 @@
|
|||||||
{
|
{
|
||||||
"id": 2,
|
"id": 2,
|
||||||
"name": "A",
|
"name": "A",
|
||||||
"nodeType": "UserDefinedTypeName",
|
"nodeType": "IdentifierPath",
|
||||||
"src": "29:1:1",
|
"src": "29:1:1"
|
||||||
"typeDescriptions": {}
|
|
||||||
},
|
},
|
||||||
"id": 3,
|
"id": 3,
|
||||||
"nodeType": "InheritanceSpecifier",
|
"nodeType": "InheritanceSpecifier",
|
||||||
@ -50,9 +49,8 @@
|
|||||||
{
|
{
|
||||||
"id": 5,
|
"id": 5,
|
||||||
"name": "B",
|
"name": "B",
|
||||||
"nodeType": "UserDefinedTypeName",
|
"nodeType": "IdentifierPath",
|
||||||
"src": "49:1:1",
|
"src": "49:1:1"
|
||||||
"typeDescriptions": {}
|
|
||||||
},
|
},
|
||||||
"id": 6,
|
"id": 6,
|
||||||
"nodeType": "InheritanceSpecifier",
|
"nodeType": "InheritanceSpecifier",
|
||||||
@ -76,9 +74,8 @@
|
|||||||
{
|
{
|
||||||
"id": 8,
|
"id": 8,
|
||||||
"name": "C",
|
"name": "C",
|
||||||
"nodeType": "UserDefinedTypeName",
|
"nodeType": "IdentifierPath",
|
||||||
"src": "69:1:1",
|
"src": "69:1:1"
|
||||||
"typeDescriptions": {}
|
|
||||||
},
|
},
|
||||||
"id": 9,
|
"id": 9,
|
||||||
"nodeType": "InheritanceSpecifier",
|
"nodeType": "InheritanceSpecifier",
|
||||||
@ -102,9 +99,8 @@
|
|||||||
{
|
{
|
||||||
"id": 11,
|
"id": 11,
|
||||||
"name": "D",
|
"name": "D",
|
||||||
"nodeType": "UserDefinedTypeName",
|
"nodeType": "IdentifierPath",
|
||||||
"src": "89:1:1",
|
"src": "89:1:1"
|
||||||
"typeDescriptions": {}
|
|
||||||
},
|
},
|
||||||
"id": 12,
|
"id": 12,
|
||||||
"nodeType": "InheritanceSpecifier",
|
"nodeType": "InheritanceSpecifier",
|
||||||
|
@ -8,10 +8,10 @@
|
|||||||
],
|
],
|
||||||
"C2":
|
"C2":
|
||||||
[
|
[
|
||||||
5
|
4
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"id": 6,
|
"id": 5,
|
||||||
"nodeType": "SourceUnit",
|
"nodeType": "SourceUnit",
|
||||||
"nodes":
|
"nodes":
|
||||||
[
|
[
|
||||||
@ -29,7 +29,7 @@
|
|||||||
"name": "C1",
|
"name": "C1",
|
||||||
"nodeType": "ContractDefinition",
|
"nodeType": "ContractDefinition",
|
||||||
"nodes": [],
|
"nodes": [],
|
||||||
"scope": 6,
|
"scope": 5,
|
||||||
"src": "0:14:1"
|
"src": "0:14:1"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -39,25 +39,13 @@
|
|||||||
{
|
{
|
||||||
"baseName":
|
"baseName":
|
||||||
{
|
{
|
||||||
"id": 3,
|
"id": 2,
|
||||||
"nodeType": "UserDefinedTypeName",
|
"name": "C1",
|
||||||
"pathNode":
|
"nodeType": "IdentifierPath",
|
||||||
{
|
|
||||||
"id": 2,
|
|
||||||
"name": "C1",
|
|
||||||
"nodeType": "IdentifierPath",
|
|
||||||
"referencedDeclaration": 1,
|
|
||||||
"src": "30:2:1"
|
|
||||||
},
|
|
||||||
"referencedDeclaration": 1,
|
"referencedDeclaration": 1,
|
||||||
"src": "30:2:1",
|
"src": "30:2:1"
|
||||||
"typeDescriptions":
|
|
||||||
{
|
|
||||||
"typeIdentifier": "t_contract$_C1_$1",
|
|
||||||
"typeString": "contract C1"
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
"id": 4,
|
"id": 3,
|
||||||
"nodeType": "InheritanceSpecifier",
|
"nodeType": "InheritanceSpecifier",
|
||||||
"src": "30:2:1"
|
"src": "30:2:1"
|
||||||
}
|
}
|
||||||
@ -68,16 +56,16 @@
|
|||||||
],
|
],
|
||||||
"contractKind": "contract",
|
"contractKind": "contract",
|
||||||
"fullyImplemented": true,
|
"fullyImplemented": true,
|
||||||
"id": 5,
|
"id": 4,
|
||||||
"linearizedBaseContracts":
|
"linearizedBaseContracts":
|
||||||
[
|
[
|
||||||
5,
|
4,
|
||||||
1
|
1
|
||||||
],
|
],
|
||||||
"name": "C2",
|
"name": "C2",
|
||||||
"nodeType": "ContractDefinition",
|
"nodeType": "ContractDefinition",
|
||||||
"nodes": [],
|
"nodes": [],
|
||||||
"scope": 6,
|
"scope": 5,
|
||||||
"src": "15:20:1"
|
"src": "15:20:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
@ -10,7 +10,7 @@
|
|||||||
],
|
],
|
||||||
"C2":
|
"C2":
|
||||||
[
|
[
|
||||||
5
|
4
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@ -39,7 +39,7 @@
|
|||||||
[
|
[
|
||||||
null
|
null
|
||||||
],
|
],
|
||||||
"scope": 6
|
"scope": 5
|
||||||
},
|
},
|
||||||
"id": 1,
|
"id": 1,
|
||||||
"name": "ContractDefinition",
|
"name": "ContractDefinition",
|
||||||
@ -57,7 +57,7 @@
|
|||||||
"fullyImplemented": true,
|
"fullyImplemented": true,
|
||||||
"linearizedBaseContracts":
|
"linearizedBaseContracts":
|
||||||
[
|
[
|
||||||
5,
|
4,
|
||||||
1
|
1
|
||||||
],
|
],
|
||||||
"name": "C2",
|
"name": "C2",
|
||||||
@ -65,7 +65,7 @@
|
|||||||
[
|
[
|
||||||
null
|
null
|
||||||
],
|
],
|
||||||
"scope": 6
|
"scope": 5
|
||||||
},
|
},
|
||||||
"children":
|
"children":
|
||||||
[
|
[
|
||||||
@ -76,38 +76,25 @@
|
|||||||
{
|
{
|
||||||
"attributes":
|
"attributes":
|
||||||
{
|
{
|
||||||
"referencedDeclaration": 1,
|
"name": "C1",
|
||||||
"type": "contract C1"
|
"referencedDeclaration": 1
|
||||||
},
|
},
|
||||||
"children":
|
"id": 2,
|
||||||
[
|
"name": "IdentifierPath",
|
||||||
{
|
|
||||||
"attributes":
|
|
||||||
{
|
|
||||||
"name": "C1",
|
|
||||||
"referencedDeclaration": 1
|
|
||||||
},
|
|
||||||
"id": 2,
|
|
||||||
"name": "IdentifierPath",
|
|
||||||
"src": "30:2:1"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"id": 3,
|
|
||||||
"name": "UserDefinedTypeName",
|
|
||||||
"src": "30:2:1"
|
"src": "30:2:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 4,
|
"id": 3,
|
||||||
"name": "InheritanceSpecifier",
|
"name": "InheritanceSpecifier",
|
||||||
"src": "30:2:1"
|
"src": "30:2:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 5,
|
"id": 4,
|
||||||
"name": "ContractDefinition",
|
"name": "ContractDefinition",
|
||||||
"src": "15:20:1"
|
"src": "15:20:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 6,
|
"id": 5,
|
||||||
"name": "SourceUnit",
|
"name": "SourceUnit",
|
||||||
"src": "0:36:1"
|
"src": "0:36:1"
|
||||||
}
|
}
|
||||||
|
@ -24,9 +24,8 @@
|
|||||||
{
|
{
|
||||||
"id": 2,
|
"id": 2,
|
||||||
"name": "C1",
|
"name": "C1",
|
||||||
"nodeType": "UserDefinedTypeName",
|
"nodeType": "IdentifierPath",
|
||||||
"src": "30:2:1",
|
"src": "30:2:1"
|
||||||
"typeDescriptions": {}
|
|
||||||
},
|
},
|
||||||
"id": 3,
|
"id": 3,
|
||||||
"nodeType": "InheritanceSpecifier",
|
"nodeType": "InheritanceSpecifier",
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"absolutePath": "a",
|
"absolutePath": "a",
|
||||||
"id": 18,
|
"id": 20,
|
||||||
"nodeType": "SourceUnit",
|
"nodeType": "SourceUnit",
|
||||||
"nodes":
|
"nodes":
|
||||||
[
|
[
|
||||||
@ -9,7 +9,7 @@
|
|||||||
"baseContracts": [],
|
"baseContracts": [],
|
||||||
"contractDependencies": [],
|
"contractDependencies": [],
|
||||||
"contractKind": "contract",
|
"contractKind": "contract",
|
||||||
"id": 17,
|
"id": 19,
|
||||||
"name": "C",
|
"name": "C",
|
||||||
"nodeType": "ContractDefinition",
|
"nodeType": "ContractDefinition",
|
||||||
"nodes":
|
"nodes":
|
||||||
@ -43,7 +43,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"constant": false,
|
"constant": false,
|
||||||
"id": 8,
|
"id": 9,
|
||||||
"mutability": "mutable",
|
"mutability": "mutable",
|
||||||
"name": "a",
|
"name": "a",
|
||||||
"nodeType": "VariableDeclaration",
|
"nodeType": "VariableDeclaration",
|
||||||
@ -53,12 +53,18 @@
|
|||||||
"typeDescriptions": {},
|
"typeDescriptions": {},
|
||||||
"typeName":
|
"typeName":
|
||||||
{
|
{
|
||||||
"id": 7,
|
"id": 8,
|
||||||
"keyType":
|
"keyType":
|
||||||
{
|
{
|
||||||
"id": 5,
|
"id": 6,
|
||||||
"name": "C",
|
|
||||||
"nodeType": "UserDefinedTypeName",
|
"nodeType": "UserDefinedTypeName",
|
||||||
|
"pathNode":
|
||||||
|
{
|
||||||
|
"id": 5,
|
||||||
|
"name": "C",
|
||||||
|
"nodeType": "IdentifierPath",
|
||||||
|
"src": "48:1:1"
|
||||||
|
},
|
||||||
"src": "48:1:1",
|
"src": "48:1:1",
|
||||||
"typeDescriptions": {}
|
"typeDescriptions": {}
|
||||||
},
|
},
|
||||||
@ -67,7 +73,7 @@
|
|||||||
"typeDescriptions": {},
|
"typeDescriptions": {},
|
||||||
"valueType":
|
"valueType":
|
||||||
{
|
{
|
||||||
"id": 6,
|
"id": 7,
|
||||||
"name": "bool",
|
"name": "bool",
|
||||||
"nodeType": "ElementaryTypeName",
|
"nodeType": "ElementaryTypeName",
|
||||||
"src": "53:4:1",
|
"src": "53:4:1",
|
||||||
@ -78,7 +84,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"constant": false,
|
"constant": false,
|
||||||
"id": 12,
|
"id": 13,
|
||||||
"mutability": "mutable",
|
"mutability": "mutable",
|
||||||
"name": "b",
|
"name": "b",
|
||||||
"nodeType": "VariableDeclaration",
|
"nodeType": "VariableDeclaration",
|
||||||
@ -88,10 +94,10 @@
|
|||||||
"typeDescriptions": {},
|
"typeDescriptions": {},
|
||||||
"typeName":
|
"typeName":
|
||||||
{
|
{
|
||||||
"id": 11,
|
"id": 12,
|
||||||
"keyType":
|
"keyType":
|
||||||
{
|
{
|
||||||
"id": 9,
|
"id": 10,
|
||||||
"name": "address",
|
"name": "address",
|
||||||
"nodeType": "ElementaryTypeName",
|
"nodeType": "ElementaryTypeName",
|
||||||
"src": "74:7:1",
|
"src": "74:7:1",
|
||||||
@ -102,7 +108,7 @@
|
|||||||
"typeDescriptions": {},
|
"typeDescriptions": {},
|
||||||
"valueType":
|
"valueType":
|
||||||
{
|
{
|
||||||
"id": 10,
|
"id": 11,
|
||||||
"name": "bool",
|
"name": "bool",
|
||||||
"nodeType": "ElementaryTypeName",
|
"nodeType": "ElementaryTypeName",
|
||||||
"src": "85:4:1",
|
"src": "85:4:1",
|
||||||
@ -113,7 +119,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"constant": false,
|
"constant": false,
|
||||||
"id": 16,
|
"id": 18,
|
||||||
"mutability": "mutable",
|
"mutability": "mutable",
|
||||||
"name": "c",
|
"name": "c",
|
||||||
"nodeType": "VariableDeclaration",
|
"nodeType": "VariableDeclaration",
|
||||||
@ -123,12 +129,18 @@
|
|||||||
"typeDescriptions": {},
|
"typeDescriptions": {},
|
||||||
"typeName":
|
"typeName":
|
||||||
{
|
{
|
||||||
"id": 15,
|
"id": 17,
|
||||||
"keyType":
|
"keyType":
|
||||||
{
|
{
|
||||||
"id": 13,
|
"id": 15,
|
||||||
"name": "E",
|
|
||||||
"nodeType": "UserDefinedTypeName",
|
"nodeType": "UserDefinedTypeName",
|
||||||
|
"pathNode":
|
||||||
|
{
|
||||||
|
"id": 14,
|
||||||
|
"name": "E",
|
||||||
|
"nodeType": "IdentifierPath",
|
||||||
|
"src": "106:1:1"
|
||||||
|
},
|
||||||
"src": "106:1:1",
|
"src": "106:1:1",
|
||||||
"typeDescriptions": {}
|
"typeDescriptions": {}
|
||||||
},
|
},
|
||||||
@ -137,7 +149,7 @@
|
|||||||
"typeDescriptions": {},
|
"typeDescriptions": {},
|
||||||
"valueType":
|
"valueType":
|
||||||
{
|
{
|
||||||
"id": 14,
|
"id": 16,
|
||||||
"name": "bool",
|
"name": "bool",
|
||||||
"nodeType": "ElementaryTypeName",
|
"nodeType": "ElementaryTypeName",
|
||||||
"src": "111:4:1",
|
"src": "111:4:1",
|
||||||
|
@ -126,15 +126,9 @@
|
|||||||
{
|
{
|
||||||
"id": 8,
|
"id": 8,
|
||||||
"name": "M",
|
"name": "M",
|
||||||
"nodeType": "Identifier",
|
"nodeType": "IdentifierPath",
|
||||||
"overloadedDeclarations": [],
|
|
||||||
"referencedDeclaration": 6,
|
"referencedDeclaration": 6,
|
||||||
"src": "52:1:1",
|
"src": "52:1:1"
|
||||||
"typeDescriptions":
|
|
||||||
{
|
|
||||||
"typeIdentifier": "t_modifier$_t_uint256_$",
|
|
||||||
"typeString": "modifier (uint256)"
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
"nodeType": "ModifierInvocation",
|
"nodeType": "ModifierInvocation",
|
||||||
"src": "52:4:1"
|
"src": "52:4:1"
|
||||||
|
@ -146,16 +146,11 @@
|
|||||||
{
|
{
|
||||||
"attributes":
|
"attributes":
|
||||||
{
|
{
|
||||||
"overloadedDeclarations":
|
"name": "M",
|
||||||
[
|
"referencedDeclaration": 6
|
||||||
null
|
|
||||||
],
|
|
||||||
"referencedDeclaration": 6,
|
|
||||||
"type": "modifier (uint256)",
|
|
||||||
"value": "M"
|
|
||||||
},
|
},
|
||||||
"id": 8,
|
"id": 8,
|
||||||
"name": "Identifier",
|
"name": "IdentifierPath",
|
||||||
"src": "52:1:1"
|
"src": "52:1:1"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -96,10 +96,8 @@
|
|||||||
{
|
{
|
||||||
"id": 8,
|
"id": 8,
|
||||||
"name": "M",
|
"name": "M",
|
||||||
"nodeType": "Identifier",
|
"nodeType": "IdentifierPath",
|
||||||
"overloadedDeclarations": [],
|
"src": "52:1:1"
|
||||||
"src": "52:1:1",
|
|
||||||
"typeDescriptions": {}
|
|
||||||
},
|
},
|
||||||
"nodeType": "ModifierInvocation",
|
"nodeType": "ModifierInvocation",
|
||||||
"src": "52:4:1"
|
"src": "52:4:1"
|
||||||
|
@ -126,15 +126,9 @@
|
|||||||
{
|
{
|
||||||
"id": 8,
|
"id": 8,
|
||||||
"name": "M",
|
"name": "M",
|
||||||
"nodeType": "Identifier",
|
"nodeType": "IdentifierPath",
|
||||||
"overloadedDeclarations": [],
|
|
||||||
"referencedDeclaration": 6,
|
"referencedDeclaration": 6,
|
||||||
"src": "52:1:1",
|
"src": "52:1:1"
|
||||||
"typeDescriptions":
|
|
||||||
{
|
|
||||||
"typeIdentifier": "t_modifier$_t_uint256_$",
|
|
||||||
"typeString": "modifier (uint256)"
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
"nodeType": "ModifierInvocation",
|
"nodeType": "ModifierInvocation",
|
||||||
"src": "52:4:1"
|
"src": "52:4:1"
|
||||||
|
@ -146,16 +146,11 @@
|
|||||||
{
|
{
|
||||||
"attributes":
|
"attributes":
|
||||||
{
|
{
|
||||||
"overloadedDeclarations":
|
"name": "M",
|
||||||
[
|
"referencedDeclaration": 6
|
||||||
null
|
|
||||||
],
|
|
||||||
"referencedDeclaration": 6,
|
|
||||||
"type": "modifier (uint256)",
|
|
||||||
"value": "M"
|
|
||||||
},
|
},
|
||||||
"id": 8,
|
"id": 8,
|
||||||
"name": "Identifier",
|
"name": "IdentifierPath",
|
||||||
"src": "52:1:1"
|
"src": "52:1:1"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -96,10 +96,8 @@
|
|||||||
{
|
{
|
||||||
"id": 8,
|
"id": 8,
|
||||||
"name": "M",
|
"name": "M",
|
||||||
"nodeType": "Identifier",
|
"nodeType": "IdentifierPath",
|
||||||
"overloadedDeclarations": [],
|
"src": "52:1:1"
|
||||||
"src": "52:1:1",
|
|
||||||
"typeDescriptions": {}
|
|
||||||
},
|
},
|
||||||
"nodeType": "ModifierInvocation",
|
"nodeType": "ModifierInvocation",
|
||||||
"src": "52:4:1"
|
"src": "52:4:1"
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"absolutePath": "a",
|
"absolutePath": "a",
|
||||||
"id": 11,
|
"id": 12,
|
||||||
"nodeType": "SourceUnit",
|
"nodeType": "SourceUnit",
|
||||||
"nodes":
|
"nodes":
|
||||||
[
|
[
|
||||||
@ -21,9 +21,8 @@
|
|||||||
{
|
{
|
||||||
"id": 2,
|
"id": 2,
|
||||||
"name": "NotExisting.X",
|
"name": "NotExisting.X",
|
||||||
"nodeType": "UserDefinedTypeName",
|
"nodeType": "IdentifierPath",
|
||||||
"src": "55:13:1",
|
"src": "55:13:1"
|
||||||
"typeDescriptions": {}
|
|
||||||
},
|
},
|
||||||
"id": 3,
|
"id": 3,
|
||||||
"nodeType": "InheritanceSpecifier",
|
"nodeType": "InheritanceSpecifier",
|
||||||
@ -32,14 +31,14 @@
|
|||||||
],
|
],
|
||||||
"contractDependencies": [],
|
"contractDependencies": [],
|
||||||
"contractKind": "contract",
|
"contractKind": "contract",
|
||||||
"id": 10,
|
"id": 11,
|
||||||
"name": "C",
|
"name": "C",
|
||||||
"nodeType": "ContractDefinition",
|
"nodeType": "ContractDefinition",
|
||||||
"nodes":
|
"nodes":
|
||||||
[
|
[
|
||||||
{
|
{
|
||||||
"constant": false,
|
"constant": false,
|
||||||
"id": 5,
|
"id": 6,
|
||||||
"mutability": "mutable",
|
"mutability": "mutable",
|
||||||
"name": "myStruct",
|
"name": "myStruct",
|
||||||
"nodeType": "VariableDeclaration",
|
"nodeType": "VariableDeclaration",
|
||||||
@ -49,9 +48,15 @@
|
|||||||
"typeDescriptions": {},
|
"typeDescriptions": {},
|
||||||
"typeName":
|
"typeName":
|
||||||
{
|
{
|
||||||
"id": 4,
|
"id": 5,
|
||||||
"name": "NotExisting.SomeStruct",
|
|
||||||
"nodeType": "UserDefinedTypeName",
|
"nodeType": "UserDefinedTypeName",
|
||||||
|
"pathNode":
|
||||||
|
{
|
||||||
|
"id": 4,
|
||||||
|
"name": "NotExisting.SomeStruct",
|
||||||
|
"nodeType": "IdentifierPath",
|
||||||
|
"src": "72:22:1"
|
||||||
|
},
|
||||||
"src": "72:22:1",
|
"src": "72:22:1",
|
||||||
"typeDescriptions": {}
|
"typeDescriptions": {}
|
||||||
},
|
},
|
||||||
@ -60,12 +65,12 @@
|
|||||||
{
|
{
|
||||||
"body":
|
"body":
|
||||||
{
|
{
|
||||||
"id": 8,
|
"id": 9,
|
||||||
"nodeType": "Block",
|
"nodeType": "Block",
|
||||||
"src": "127:2:1",
|
"src": "127:2:1",
|
||||||
"statements": []
|
"statements": []
|
||||||
},
|
},
|
||||||
"id": 9,
|
"id": 10,
|
||||||
"implemented": true,
|
"implemented": true,
|
||||||
"kind": "constructor",
|
"kind": "constructor",
|
||||||
"modifiers": [],
|
"modifiers": [],
|
||||||
@ -73,14 +78,14 @@
|
|||||||
"nodeType": "FunctionDefinition",
|
"nodeType": "FunctionDefinition",
|
||||||
"parameters":
|
"parameters":
|
||||||
{
|
{
|
||||||
"id": 6,
|
"id": 7,
|
||||||
"nodeType": "ParameterList",
|
"nodeType": "ParameterList",
|
||||||
"parameters": [],
|
"parameters": [],
|
||||||
"src": "124:2:1"
|
"src": "124:2:1"
|
||||||
},
|
},
|
||||||
"returnParameters":
|
"returnParameters":
|
||||||
{
|
{
|
||||||
"id": 7,
|
"id": 8,
|
||||||
"nodeType": "ParameterList",
|
"nodeType": "ParameterList",
|
||||||
"parameters": [],
|
"parameters": [],
|
||||||
"src": "127:0:1"
|
"src": "127:0:1"
|
||||||
|
@ -8,14 +8,14 @@
|
|||||||
],
|
],
|
||||||
"B":
|
"B":
|
||||||
[
|
[
|
||||||
17
|
16
|
||||||
],
|
],
|
||||||
"C":
|
"C":
|
||||||
[
|
[
|
||||||
35
|
31
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"id": 36,
|
"id": 32,
|
||||||
"nodeType": "SourceUnit",
|
"nodeType": "SourceUnit",
|
||||||
"nodes":
|
"nodes":
|
||||||
[
|
[
|
||||||
@ -70,7 +70,7 @@
|
|||||||
"visibility": "public"
|
"visibility": "public"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"scope": 36,
|
"scope": 32,
|
||||||
"src": "0:40:1"
|
"src": "0:40:1"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -80,25 +80,13 @@
|
|||||||
{
|
{
|
||||||
"baseName":
|
"baseName":
|
||||||
{
|
{
|
||||||
"id": 7,
|
"id": 6,
|
||||||
"nodeType": "UserDefinedTypeName",
|
"name": "A",
|
||||||
"pathNode":
|
"nodeType": "IdentifierPath",
|
||||||
{
|
|
||||||
"id": 6,
|
|
||||||
"name": "A",
|
|
||||||
"nodeType": "IdentifierPath",
|
|
||||||
"referencedDeclaration": 5,
|
|
||||||
"src": "55:1:1"
|
|
||||||
},
|
|
||||||
"referencedDeclaration": 5,
|
"referencedDeclaration": 5,
|
||||||
"src": "55:1:1",
|
"src": "55:1:1"
|
||||||
"typeDescriptions":
|
|
||||||
{
|
|
||||||
"typeIdentifier": "t_contract$_A_$5",
|
|
||||||
"typeString": "contract A"
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
"id": 8,
|
"id": 7,
|
||||||
"nodeType": "InheritanceSpecifier",
|
"nodeType": "InheritanceSpecifier",
|
||||||
"src": "55:1:1"
|
"src": "55:1:1"
|
||||||
}
|
}
|
||||||
@ -109,10 +97,10 @@
|
|||||||
],
|
],
|
||||||
"contractKind": "contract",
|
"contractKind": "contract",
|
||||||
"fullyImplemented": false,
|
"fullyImplemented": false,
|
||||||
"id": 17,
|
"id": 16,
|
||||||
"linearizedBaseContracts":
|
"linearizedBaseContracts":
|
||||||
[
|
[
|
||||||
17,
|
16,
|
||||||
5
|
5
|
||||||
],
|
],
|
||||||
"name": "B",
|
"name": "B",
|
||||||
@ -121,7 +109,7 @@
|
|||||||
[
|
[
|
||||||
{
|
{
|
||||||
"functionSelector": "c2985578",
|
"functionSelector": "c2985578",
|
||||||
"id": 11,
|
"id": 10,
|
||||||
"implemented": false,
|
"implemented": false,
|
||||||
"kind": "function",
|
"kind": "function",
|
||||||
"modifiers": [],
|
"modifiers": [],
|
||||||
@ -129,19 +117,19 @@
|
|||||||
"nodeType": "FunctionDefinition",
|
"nodeType": "FunctionDefinition",
|
||||||
"parameters":
|
"parameters":
|
||||||
{
|
{
|
||||||
"id": 9,
|
"id": 8,
|
||||||
"nodeType": "ParameterList",
|
"nodeType": "ParameterList",
|
||||||
"parameters": [],
|
"parameters": [],
|
||||||
"src": "72:2:1"
|
"src": "72:2:1"
|
||||||
},
|
},
|
||||||
"returnParameters":
|
"returnParameters":
|
||||||
{
|
{
|
||||||
"id": 10,
|
"id": 9,
|
||||||
"nodeType": "ParameterList",
|
"nodeType": "ParameterList",
|
||||||
"parameters": [],
|
"parameters": [],
|
||||||
"src": "81:0:1"
|
"src": "81:0:1"
|
||||||
},
|
},
|
||||||
"scope": 17,
|
"scope": 16,
|
||||||
"src": "60:22:1",
|
"src": "60:22:1",
|
||||||
"stateMutability": "nonpayable",
|
"stateMutability": "nonpayable",
|
||||||
"virtual": false,
|
"virtual": false,
|
||||||
@ -154,13 +142,13 @@
|
|||||||
],
|
],
|
||||||
"body":
|
"body":
|
||||||
{
|
{
|
||||||
"id": 15,
|
"id": 14,
|
||||||
"nodeType": "Block",
|
"nodeType": "Block",
|
||||||
"src": "115:2:1",
|
"src": "115:2:1",
|
||||||
"statements": []
|
"statements": []
|
||||||
},
|
},
|
||||||
"functionSelector": "a399b6a2",
|
"functionSelector": "a399b6a2",
|
||||||
"id": 16,
|
"id": 15,
|
||||||
"implemented": true,
|
"implemented": true,
|
||||||
"kind": "function",
|
"kind": "function",
|
||||||
"modifiers": [],
|
"modifiers": [],
|
||||||
@ -168,33 +156,33 @@
|
|||||||
"nodeType": "FunctionDefinition",
|
"nodeType": "FunctionDefinition",
|
||||||
"overrides":
|
"overrides":
|
||||||
{
|
{
|
||||||
"id": 13,
|
"id": 12,
|
||||||
"nodeType": "OverrideSpecifier",
|
"nodeType": "OverrideSpecifier",
|
||||||
"overrides": [],
|
"overrides": [],
|
||||||
"src": "106:8:1"
|
"src": "106:8:1"
|
||||||
},
|
},
|
||||||
"parameters":
|
"parameters":
|
||||||
{
|
{
|
||||||
"id": 12,
|
"id": 11,
|
||||||
"nodeType": "ParameterList",
|
"nodeType": "ParameterList",
|
||||||
"parameters": [],
|
"parameters": [],
|
||||||
"src": "96:2:1"
|
"src": "96:2:1"
|
||||||
},
|
},
|
||||||
"returnParameters":
|
"returnParameters":
|
||||||
{
|
{
|
||||||
"id": 14,
|
"id": 13,
|
||||||
"nodeType": "ParameterList",
|
"nodeType": "ParameterList",
|
||||||
"parameters": [],
|
"parameters": [],
|
||||||
"src": "115:0:1"
|
"src": "115:0:1"
|
||||||
},
|
},
|
||||||
"scope": 17,
|
"scope": 16,
|
||||||
"src": "84:33:1",
|
"src": "84:33:1",
|
||||||
"stateMutability": "nonpayable",
|
"stateMutability": "nonpayable",
|
||||||
"virtual": false,
|
"virtual": false,
|
||||||
"visibility": "public"
|
"visibility": "public"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"scope": 36,
|
"scope": 32,
|
||||||
"src": "41:78:1"
|
"src": "41:78:1"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -204,25 +192,13 @@
|
|||||||
{
|
{
|
||||||
"baseName":
|
"baseName":
|
||||||
{
|
{
|
||||||
"id": 19,
|
"id": 17,
|
||||||
"nodeType": "UserDefinedTypeName",
|
"name": "B",
|
||||||
"pathNode":
|
"nodeType": "IdentifierPath",
|
||||||
{
|
"referencedDeclaration": 16,
|
||||||
"id": 18,
|
"src": "134:1:1"
|
||||||
"name": "B",
|
|
||||||
"nodeType": "IdentifierPath",
|
|
||||||
"referencedDeclaration": 17,
|
|
||||||
"src": "134:1:1"
|
|
||||||
},
|
|
||||||
"referencedDeclaration": 17,
|
|
||||||
"src": "134:1:1",
|
|
||||||
"typeDescriptions":
|
|
||||||
{
|
|
||||||
"typeIdentifier": "t_contract$_B_$17",
|
|
||||||
"typeString": "contract B"
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
"id": 20,
|
"id": 18,
|
||||||
"nodeType": "InheritanceSpecifier",
|
"nodeType": "InheritanceSpecifier",
|
||||||
"src": "134:1:1"
|
"src": "134:1:1"
|
||||||
}
|
}
|
||||||
@ -230,15 +206,15 @@
|
|||||||
"contractDependencies":
|
"contractDependencies":
|
||||||
[
|
[
|
||||||
5,
|
5,
|
||||||
17
|
16
|
||||||
],
|
],
|
||||||
"contractKind": "contract",
|
"contractKind": "contract",
|
||||||
"fullyImplemented": true,
|
"fullyImplemented": true,
|
||||||
"id": 35,
|
"id": 31,
|
||||||
"linearizedBaseContracts":
|
"linearizedBaseContracts":
|
||||||
[
|
[
|
||||||
35,
|
31,
|
||||||
17,
|
16,
|
||||||
5
|
5
|
||||||
],
|
],
|
||||||
"name": "C",
|
"name": "C",
|
||||||
@ -248,17 +224,17 @@
|
|||||||
{
|
{
|
||||||
"baseFunctions":
|
"baseFunctions":
|
||||||
[
|
[
|
||||||
11
|
10
|
||||||
],
|
],
|
||||||
"body":
|
"body":
|
||||||
{
|
{
|
||||||
"id": 24,
|
"id": 22,
|
||||||
"nodeType": "Block",
|
"nodeType": "Block",
|
||||||
"src": "170:3:1",
|
"src": "170:3:1",
|
||||||
"statements": []
|
"statements": []
|
||||||
},
|
},
|
||||||
"functionSelector": "c2985578",
|
"functionSelector": "c2985578",
|
||||||
"id": 25,
|
"id": 23,
|
||||||
"implemented": true,
|
"implemented": true,
|
||||||
"kind": "function",
|
"kind": "function",
|
||||||
"modifiers": [],
|
"modifiers": [],
|
||||||
@ -266,26 +242,26 @@
|
|||||||
"nodeType": "FunctionDefinition",
|
"nodeType": "FunctionDefinition",
|
||||||
"overrides":
|
"overrides":
|
||||||
{
|
{
|
||||||
"id": 22,
|
"id": 20,
|
||||||
"nodeType": "OverrideSpecifier",
|
"nodeType": "OverrideSpecifier",
|
||||||
"overrides": [],
|
"overrides": [],
|
||||||
"src": "161:8:1"
|
"src": "161:8:1"
|
||||||
},
|
},
|
||||||
"parameters":
|
"parameters":
|
||||||
{
|
{
|
||||||
"id": 21,
|
"id": 19,
|
||||||
"nodeType": "ParameterList",
|
"nodeType": "ParameterList",
|
||||||
"parameters": [],
|
"parameters": [],
|
||||||
"src": "151:2:1"
|
"src": "151:2:1"
|
||||||
},
|
},
|
||||||
"returnParameters":
|
"returnParameters":
|
||||||
{
|
{
|
||||||
"id": 23,
|
"id": 21,
|
||||||
"nodeType": "ParameterList",
|
"nodeType": "ParameterList",
|
||||||
"parameters": [],
|
"parameters": [],
|
||||||
"src": "170:0:1"
|
"src": "170:0:1"
|
||||||
},
|
},
|
||||||
"scope": 35,
|
"scope": 31,
|
||||||
"src": "139:34:1",
|
"src": "139:34:1",
|
||||||
"stateMutability": "nonpayable",
|
"stateMutability": "nonpayable",
|
||||||
"virtual": false,
|
"virtual": false,
|
||||||
@ -294,17 +270,17 @@
|
|||||||
{
|
{
|
||||||
"baseFunctions":
|
"baseFunctions":
|
||||||
[
|
[
|
||||||
16
|
15
|
||||||
],
|
],
|
||||||
"body":
|
"body":
|
||||||
{
|
{
|
||||||
"id": 33,
|
"id": 29,
|
||||||
"nodeType": "Block",
|
"nodeType": "Block",
|
||||||
"src": "212:2:1",
|
"src": "212:2:1",
|
||||||
"statements": []
|
"statements": []
|
||||||
},
|
},
|
||||||
"functionSelector": "a399b6a2",
|
"functionSelector": "a399b6a2",
|
||||||
"id": 34,
|
"id": 30,
|
||||||
"implemented": true,
|
"implemented": true,
|
||||||
"kind": "function",
|
"kind": "function",
|
||||||
"modifiers": [],
|
"modifiers": [],
|
||||||
@ -312,73 +288,49 @@
|
|||||||
"nodeType": "FunctionDefinition",
|
"nodeType": "FunctionDefinition",
|
||||||
"overrides":
|
"overrides":
|
||||||
{
|
{
|
||||||
"id": 31,
|
"id": 27,
|
||||||
"nodeType": "OverrideSpecifier",
|
"nodeType": "OverrideSpecifier",
|
||||||
"overrides":
|
"overrides":
|
||||||
[
|
[
|
||||||
{
|
{
|
||||||
"id": 28,
|
"id": 25,
|
||||||
"nodeType": "UserDefinedTypeName",
|
"name": "A",
|
||||||
"pathNode":
|
"nodeType": "IdentifierPath",
|
||||||
{
|
|
||||||
"id": 27,
|
|
||||||
"name": "A",
|
|
||||||
"nodeType": "IdentifierPath",
|
|
||||||
"referencedDeclaration": 5,
|
|
||||||
"src": "206:1:1"
|
|
||||||
},
|
|
||||||
"referencedDeclaration": 5,
|
"referencedDeclaration": 5,
|
||||||
"src": "206:1:1",
|
"src": "206:1:1"
|
||||||
"typeDescriptions":
|
|
||||||
{
|
|
||||||
"typeIdentifier": "t_contract$_A_$5",
|
|
||||||
"typeString": "contract A"
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"id": 30,
|
"id": 26,
|
||||||
"nodeType": "UserDefinedTypeName",
|
"name": "B",
|
||||||
"pathNode":
|
"nodeType": "IdentifierPath",
|
||||||
{
|
"referencedDeclaration": 16,
|
||||||
"id": 29,
|
"src": "209:1:1"
|
||||||
"name": "B",
|
|
||||||
"nodeType": "IdentifierPath",
|
|
||||||
"referencedDeclaration": 17,
|
|
||||||
"src": "209:1:1"
|
|
||||||
},
|
|
||||||
"referencedDeclaration": 17,
|
|
||||||
"src": "209:1:1",
|
|
||||||
"typeDescriptions":
|
|
||||||
{
|
|
||||||
"typeIdentifier": "t_contract$_B_$17",
|
|
||||||
"typeString": "contract B"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"src": "197:14:1"
|
"src": "197:14:1"
|
||||||
},
|
},
|
||||||
"parameters":
|
"parameters":
|
||||||
{
|
{
|
||||||
"id": 26,
|
"id": 24,
|
||||||
"nodeType": "ParameterList",
|
"nodeType": "ParameterList",
|
||||||
"parameters": [],
|
"parameters": [],
|
||||||
"src": "187:2:1"
|
"src": "187:2:1"
|
||||||
},
|
},
|
||||||
"returnParameters":
|
"returnParameters":
|
||||||
{
|
{
|
||||||
"id": 32,
|
"id": 28,
|
||||||
"nodeType": "ParameterList",
|
"nodeType": "ParameterList",
|
||||||
"parameters": [],
|
"parameters": [],
|
||||||
"src": "212:0:1"
|
"src": "212:0:1"
|
||||||
},
|
},
|
||||||
"scope": 35,
|
"scope": 31,
|
||||||
"src": "175:39:1",
|
"src": "175:39:1",
|
||||||
"stateMutability": "nonpayable",
|
"stateMutability": "nonpayable",
|
||||||
"virtual": false,
|
"virtual": false,
|
||||||
"visibility": "public"
|
"visibility": "public"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"scope": 36,
|
"scope": 32,
|
||||||
"src": "120:96:1"
|
"src": "120:96:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
@ -10,11 +10,11 @@
|
|||||||
],
|
],
|
||||||
"B":
|
"B":
|
||||||
[
|
[
|
||||||
17
|
16
|
||||||
],
|
],
|
||||||
"C":
|
"C":
|
||||||
[
|
[
|
||||||
35
|
31
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@ -39,7 +39,7 @@
|
|||||||
5
|
5
|
||||||
],
|
],
|
||||||
"name": "A",
|
"name": "A",
|
||||||
"scope": 36
|
"scope": 32
|
||||||
},
|
},
|
||||||
"children":
|
"children":
|
||||||
[
|
[
|
||||||
@ -123,11 +123,11 @@
|
|||||||
"fullyImplemented": false,
|
"fullyImplemented": false,
|
||||||
"linearizedBaseContracts":
|
"linearizedBaseContracts":
|
||||||
[
|
[
|
||||||
17,
|
16,
|
||||||
5
|
5
|
||||||
],
|
],
|
||||||
"name": "B",
|
"name": "B",
|
||||||
"scope": 36
|
"scope": 32
|
||||||
},
|
},
|
||||||
"children":
|
"children":
|
||||||
[
|
[
|
||||||
@ -138,28 +138,15 @@
|
|||||||
{
|
{
|
||||||
"attributes":
|
"attributes":
|
||||||
{
|
{
|
||||||
"referencedDeclaration": 5,
|
"name": "A",
|
||||||
"type": "contract A"
|
"referencedDeclaration": 5
|
||||||
},
|
},
|
||||||
"children":
|
"id": 6,
|
||||||
[
|
"name": "IdentifierPath",
|
||||||
{
|
|
||||||
"attributes":
|
|
||||||
{
|
|
||||||
"name": "A",
|
|
||||||
"referencedDeclaration": 5
|
|
||||||
},
|
|
||||||
"id": 6,
|
|
||||||
"name": "IdentifierPath",
|
|
||||||
"src": "55:1:1"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"id": 7,
|
|
||||||
"name": "UserDefinedTypeName",
|
|
||||||
"src": "55:1:1"
|
"src": "55:1:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 8,
|
"id": 7,
|
||||||
"name": "InheritanceSpecifier",
|
"name": "InheritanceSpecifier",
|
||||||
"src": "55:1:1"
|
"src": "55:1:1"
|
||||||
},
|
},
|
||||||
@ -175,7 +162,7 @@
|
|||||||
null
|
null
|
||||||
],
|
],
|
||||||
"name": "foo",
|
"name": "foo",
|
||||||
"scope": 17,
|
"scope": 16,
|
||||||
"stateMutability": "nonpayable",
|
"stateMutability": "nonpayable",
|
||||||
"virtual": false,
|
"virtual": false,
|
||||||
"visibility": "public"
|
"visibility": "public"
|
||||||
@ -191,7 +178,7 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"children": [],
|
"children": [],
|
||||||
"id": 9,
|
"id": 8,
|
||||||
"name": "ParameterList",
|
"name": "ParameterList",
|
||||||
"src": "72:2:1"
|
"src": "72:2:1"
|
||||||
},
|
},
|
||||||
@ -204,12 +191,12 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"children": [],
|
"children": [],
|
||||||
"id": 10,
|
"id": 9,
|
||||||
"name": "ParameterList",
|
"name": "ParameterList",
|
||||||
"src": "81:0:1"
|
"src": "81:0:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 11,
|
"id": 10,
|
||||||
"name": "FunctionDefinition",
|
"name": "FunctionDefinition",
|
||||||
"src": "60:22:1"
|
"src": "60:22:1"
|
||||||
},
|
},
|
||||||
@ -229,7 +216,7 @@
|
|||||||
null
|
null
|
||||||
],
|
],
|
||||||
"name": "faa",
|
"name": "faa",
|
||||||
"scope": 17,
|
"scope": 16,
|
||||||
"stateMutability": "nonpayable",
|
"stateMutability": "nonpayable",
|
||||||
"virtual": false,
|
"virtual": false,
|
||||||
"visibility": "public"
|
"visibility": "public"
|
||||||
@ -244,7 +231,7 @@
|
|||||||
null
|
null
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"id": 13,
|
"id": 12,
|
||||||
"name": "OverrideSpecifier",
|
"name": "OverrideSpecifier",
|
||||||
"src": "106:8:1"
|
"src": "106:8:1"
|
||||||
},
|
},
|
||||||
@ -257,7 +244,7 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"children": [],
|
"children": [],
|
||||||
"id": 12,
|
"id": 11,
|
||||||
"name": "ParameterList",
|
"name": "ParameterList",
|
||||||
"src": "96:2:1"
|
"src": "96:2:1"
|
||||||
},
|
},
|
||||||
@ -270,7 +257,7 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"children": [],
|
"children": [],
|
||||||
"id": 14,
|
"id": 13,
|
||||||
"name": "ParameterList",
|
"name": "ParameterList",
|
||||||
"src": "115:0:1"
|
"src": "115:0:1"
|
||||||
},
|
},
|
||||||
@ -283,17 +270,17 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"children": [],
|
"children": [],
|
||||||
"id": 15,
|
"id": 14,
|
||||||
"name": "Block",
|
"name": "Block",
|
||||||
"src": "115:2:1"
|
"src": "115:2:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 16,
|
"id": 15,
|
||||||
"name": "FunctionDefinition",
|
"name": "FunctionDefinition",
|
||||||
"src": "84:33:1"
|
"src": "84:33:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 17,
|
"id": 16,
|
||||||
"name": "ContractDefinition",
|
"name": "ContractDefinition",
|
||||||
"src": "41:78:1"
|
"src": "41:78:1"
|
||||||
},
|
},
|
||||||
@ -304,18 +291,18 @@
|
|||||||
"contractDependencies":
|
"contractDependencies":
|
||||||
[
|
[
|
||||||
5,
|
5,
|
||||||
17
|
16
|
||||||
],
|
],
|
||||||
"contractKind": "contract",
|
"contractKind": "contract",
|
||||||
"fullyImplemented": true,
|
"fullyImplemented": true,
|
||||||
"linearizedBaseContracts":
|
"linearizedBaseContracts":
|
||||||
[
|
[
|
||||||
35,
|
31,
|
||||||
17,
|
16,
|
||||||
5
|
5
|
||||||
],
|
],
|
||||||
"name": "C",
|
"name": "C",
|
||||||
"scope": 36
|
"scope": 32
|
||||||
},
|
},
|
||||||
"children":
|
"children":
|
||||||
[
|
[
|
||||||
@ -326,28 +313,15 @@
|
|||||||
{
|
{
|
||||||
"attributes":
|
"attributes":
|
||||||
{
|
{
|
||||||
"referencedDeclaration": 17,
|
"name": "B",
|
||||||
"type": "contract B"
|
"referencedDeclaration": 16
|
||||||
},
|
},
|
||||||
"children":
|
"id": 17,
|
||||||
[
|
"name": "IdentifierPath",
|
||||||
{
|
|
||||||
"attributes":
|
|
||||||
{
|
|
||||||
"name": "B",
|
|
||||||
"referencedDeclaration": 17
|
|
||||||
},
|
|
||||||
"id": 18,
|
|
||||||
"name": "IdentifierPath",
|
|
||||||
"src": "134:1:1"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"id": 19,
|
|
||||||
"name": "UserDefinedTypeName",
|
|
||||||
"src": "134:1:1"
|
"src": "134:1:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 20,
|
"id": 18,
|
||||||
"name": "InheritanceSpecifier",
|
"name": "InheritanceSpecifier",
|
||||||
"src": "134:1:1"
|
"src": "134:1:1"
|
||||||
},
|
},
|
||||||
@ -356,7 +330,7 @@
|
|||||||
{
|
{
|
||||||
"baseFunctions":
|
"baseFunctions":
|
||||||
[
|
[
|
||||||
11
|
10
|
||||||
],
|
],
|
||||||
"functionSelector": "c2985578",
|
"functionSelector": "c2985578",
|
||||||
"implemented": true,
|
"implemented": true,
|
||||||
@ -367,7 +341,7 @@
|
|||||||
null
|
null
|
||||||
],
|
],
|
||||||
"name": "foo",
|
"name": "foo",
|
||||||
"scope": 35,
|
"scope": 31,
|
||||||
"stateMutability": "nonpayable",
|
"stateMutability": "nonpayable",
|
||||||
"virtual": false,
|
"virtual": false,
|
||||||
"visibility": "public"
|
"visibility": "public"
|
||||||
@ -382,7 +356,7 @@
|
|||||||
null
|
null
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"id": 22,
|
"id": 20,
|
||||||
"name": "OverrideSpecifier",
|
"name": "OverrideSpecifier",
|
||||||
"src": "161:8:1"
|
"src": "161:8:1"
|
||||||
},
|
},
|
||||||
@ -395,7 +369,7 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"children": [],
|
"children": [],
|
||||||
"id": 21,
|
"id": 19,
|
||||||
"name": "ParameterList",
|
"name": "ParameterList",
|
||||||
"src": "151:2:1"
|
"src": "151:2:1"
|
||||||
},
|
},
|
||||||
@ -408,7 +382,7 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"children": [],
|
"children": [],
|
||||||
"id": 23,
|
"id": 21,
|
||||||
"name": "ParameterList",
|
"name": "ParameterList",
|
||||||
"src": "170:0:1"
|
"src": "170:0:1"
|
||||||
},
|
},
|
||||||
@ -421,12 +395,12 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"children": [],
|
"children": [],
|
||||||
"id": 24,
|
"id": 22,
|
||||||
"name": "Block",
|
"name": "Block",
|
||||||
"src": "170:3:1"
|
"src": "170:3:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 25,
|
"id": 23,
|
||||||
"name": "FunctionDefinition",
|
"name": "FunctionDefinition",
|
||||||
"src": "139:34:1"
|
"src": "139:34:1"
|
||||||
},
|
},
|
||||||
@ -435,7 +409,7 @@
|
|||||||
{
|
{
|
||||||
"baseFunctions":
|
"baseFunctions":
|
||||||
[
|
[
|
||||||
16
|
15
|
||||||
],
|
],
|
||||||
"functionSelector": "a399b6a2",
|
"functionSelector": "a399b6a2",
|
||||||
"implemented": true,
|
"implemented": true,
|
||||||
@ -446,7 +420,7 @@
|
|||||||
null
|
null
|
||||||
],
|
],
|
||||||
"name": "faa",
|
"name": "faa",
|
||||||
"scope": 35,
|
"scope": 31,
|
||||||
"stateMutability": "nonpayable",
|
"stateMutability": "nonpayable",
|
||||||
"virtual": false,
|
"virtual": false,
|
||||||
"visibility": "public"
|
"visibility": "public"
|
||||||
@ -459,51 +433,25 @@
|
|||||||
{
|
{
|
||||||
"attributes":
|
"attributes":
|
||||||
{
|
{
|
||||||
"referencedDeclaration": 5,
|
"name": "A",
|
||||||
"type": "contract A"
|
"referencedDeclaration": 5
|
||||||
},
|
},
|
||||||
"children":
|
"id": 25,
|
||||||
[
|
"name": "IdentifierPath",
|
||||||
{
|
|
||||||
"attributes":
|
|
||||||
{
|
|
||||||
"name": "A",
|
|
||||||
"referencedDeclaration": 5
|
|
||||||
},
|
|
||||||
"id": 27,
|
|
||||||
"name": "IdentifierPath",
|
|
||||||
"src": "206:1:1"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"id": 28,
|
|
||||||
"name": "UserDefinedTypeName",
|
|
||||||
"src": "206:1:1"
|
"src": "206:1:1"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"attributes":
|
"attributes":
|
||||||
{
|
{
|
||||||
"referencedDeclaration": 17,
|
"name": "B",
|
||||||
"type": "contract B"
|
"referencedDeclaration": 16
|
||||||
},
|
},
|
||||||
"children":
|
"id": 26,
|
||||||
[
|
"name": "IdentifierPath",
|
||||||
{
|
|
||||||
"attributes":
|
|
||||||
{
|
|
||||||
"name": "B",
|
|
||||||
"referencedDeclaration": 17
|
|
||||||
},
|
|
||||||
"id": 29,
|
|
||||||
"name": "IdentifierPath",
|
|
||||||
"src": "209:1:1"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"id": 30,
|
|
||||||
"name": "UserDefinedTypeName",
|
|
||||||
"src": "209:1:1"
|
"src": "209:1:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 31,
|
"id": 27,
|
||||||
"name": "OverrideSpecifier",
|
"name": "OverrideSpecifier",
|
||||||
"src": "197:14:1"
|
"src": "197:14:1"
|
||||||
},
|
},
|
||||||
@ -516,7 +464,7 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"children": [],
|
"children": [],
|
||||||
"id": 26,
|
"id": 24,
|
||||||
"name": "ParameterList",
|
"name": "ParameterList",
|
||||||
"src": "187:2:1"
|
"src": "187:2:1"
|
||||||
},
|
},
|
||||||
@ -529,7 +477,7 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"children": [],
|
"children": [],
|
||||||
"id": 32,
|
"id": 28,
|
||||||
"name": "ParameterList",
|
"name": "ParameterList",
|
||||||
"src": "212:0:1"
|
"src": "212:0:1"
|
||||||
},
|
},
|
||||||
@ -542,22 +490,22 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"children": [],
|
"children": [],
|
||||||
"id": 33,
|
"id": 29,
|
||||||
"name": "Block",
|
"name": "Block",
|
||||||
"src": "212:2:1"
|
"src": "212:2:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 34,
|
"id": 30,
|
||||||
"name": "FunctionDefinition",
|
"name": "FunctionDefinition",
|
||||||
"src": "175:39:1"
|
"src": "175:39:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 35,
|
"id": 31,
|
||||||
"name": "ContractDefinition",
|
"name": "ContractDefinition",
|
||||||
"src": "120:96:1"
|
"src": "120:96:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 36,
|
"id": 32,
|
||||||
"name": "SourceUnit",
|
"name": "SourceUnit",
|
||||||
"src": "0:217:1"
|
"src": "0:217:1"
|
||||||
}
|
}
|
||||||
|
@ -59,9 +59,8 @@
|
|||||||
{
|
{
|
||||||
"id": 6,
|
"id": 6,
|
||||||
"name": "A",
|
"name": "A",
|
||||||
"nodeType": "UserDefinedTypeName",
|
"nodeType": "IdentifierPath",
|
||||||
"src": "55:1:1",
|
"src": "55:1:1"
|
||||||
"typeDescriptions": {}
|
|
||||||
},
|
},
|
||||||
"id": 7,
|
"id": 7,
|
||||||
"nodeType": "InheritanceSpecifier",
|
"nodeType": "InheritanceSpecifier",
|
||||||
@ -153,9 +152,8 @@
|
|||||||
{
|
{
|
||||||
"id": 17,
|
"id": 17,
|
||||||
"name": "B",
|
"name": "B",
|
||||||
"nodeType": "UserDefinedTypeName",
|
"nodeType": "IdentifierPath",
|
||||||
"src": "134:1:1",
|
"src": "134:1:1"
|
||||||
"typeDescriptions": {}
|
|
||||||
},
|
},
|
||||||
"id": 18,
|
"id": 18,
|
||||||
"nodeType": "InheritanceSpecifier",
|
"nodeType": "InheritanceSpecifier",
|
||||||
@ -232,16 +230,14 @@
|
|||||||
{
|
{
|
||||||
"id": 25,
|
"id": 25,
|
||||||
"name": "A",
|
"name": "A",
|
||||||
"nodeType": "UserDefinedTypeName",
|
"nodeType": "IdentifierPath",
|
||||||
"src": "206:1:1",
|
"src": "206:1:1"
|
||||||
"typeDescriptions": {}
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"id": 26,
|
"id": 26,
|
||||||
"name": "B",
|
"name": "B",
|
||||||
"nodeType": "UserDefinedTypeName",
|
"nodeType": "IdentifierPath",
|
||||||
"src": "209:1:1",
|
"src": "209:1:1"
|
||||||
"typeDescriptions": {}
|
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"src": "197:14:1"
|
"src": "197:14:1"
|
||||||
|
@ -12,10 +12,10 @@
|
|||||||
],
|
],
|
||||||
"C":
|
"C":
|
||||||
[
|
[
|
||||||
26
|
22
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"id": 27,
|
"id": 23,
|
||||||
"nodeType": "SourceUnit",
|
"nodeType": "SourceUnit",
|
||||||
"nodes":
|
"nodes":
|
||||||
[
|
[
|
||||||
@ -70,7 +70,7 @@
|
|||||||
"visibility": "public"
|
"visibility": "public"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"scope": 27,
|
"scope": 23,
|
||||||
"src": "0:49:1"
|
"src": "0:49:1"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -124,7 +124,7 @@
|
|||||||
"visibility": "public"
|
"visibility": "public"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"scope": 27,
|
"scope": 23,
|
||||||
"src": "50:49:1"
|
"src": "50:49:1"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -134,50 +134,26 @@
|
|||||||
{
|
{
|
||||||
"baseName":
|
"baseName":
|
||||||
{
|
{
|
||||||
"id": 12,
|
"id": 11,
|
||||||
"nodeType": "UserDefinedTypeName",
|
"name": "A",
|
||||||
"pathNode":
|
"nodeType": "IdentifierPath",
|
||||||
{
|
|
||||||
"id": 11,
|
|
||||||
"name": "A",
|
|
||||||
"nodeType": "IdentifierPath",
|
|
||||||
"referencedDeclaration": 5,
|
|
||||||
"src": "114:1:1"
|
|
||||||
},
|
|
||||||
"referencedDeclaration": 5,
|
"referencedDeclaration": 5,
|
||||||
"src": "114:1:1",
|
"src": "114:1:1"
|
||||||
"typeDescriptions":
|
|
||||||
{
|
|
||||||
"typeIdentifier": "t_contract$_A_$5",
|
|
||||||
"typeString": "contract A"
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
"id": 13,
|
"id": 12,
|
||||||
"nodeType": "InheritanceSpecifier",
|
"nodeType": "InheritanceSpecifier",
|
||||||
"src": "114:1:1"
|
"src": "114:1:1"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"baseName":
|
"baseName":
|
||||||
{
|
{
|
||||||
"id": 15,
|
"id": 13,
|
||||||
"nodeType": "UserDefinedTypeName",
|
"name": "B",
|
||||||
"pathNode":
|
"nodeType": "IdentifierPath",
|
||||||
{
|
|
||||||
"id": 14,
|
|
||||||
"name": "B",
|
|
||||||
"nodeType": "IdentifierPath",
|
|
||||||
"referencedDeclaration": 10,
|
|
||||||
"src": "117:1:1"
|
|
||||||
},
|
|
||||||
"referencedDeclaration": 10,
|
"referencedDeclaration": 10,
|
||||||
"src": "117:1:1",
|
"src": "117:1:1"
|
||||||
"typeDescriptions":
|
|
||||||
{
|
|
||||||
"typeIdentifier": "t_contract$_B_$10",
|
|
||||||
"typeString": "contract B"
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
"id": 16,
|
"id": 14,
|
||||||
"nodeType": "InheritanceSpecifier",
|
"nodeType": "InheritanceSpecifier",
|
||||||
"src": "117:1:1"
|
"src": "117:1:1"
|
||||||
}
|
}
|
||||||
@ -189,10 +165,10 @@
|
|||||||
],
|
],
|
||||||
"contractKind": "contract",
|
"contractKind": "contract",
|
||||||
"fullyImplemented": true,
|
"fullyImplemented": true,
|
||||||
"id": 26,
|
"id": 22,
|
||||||
"linearizedBaseContracts":
|
"linearizedBaseContracts":
|
||||||
[
|
[
|
||||||
26,
|
22,
|
||||||
10,
|
10,
|
||||||
5
|
5
|
||||||
],
|
],
|
||||||
@ -208,13 +184,13 @@
|
|||||||
],
|
],
|
||||||
"body":
|
"body":
|
||||||
{
|
{
|
||||||
"id": 24,
|
"id": 20,
|
||||||
"nodeType": "Block",
|
"nodeType": "Block",
|
||||||
"src": "160:2:1",
|
"src": "160:2:1",
|
||||||
"statements": []
|
"statements": []
|
||||||
},
|
},
|
||||||
"functionSelector": "26121ff0",
|
"functionSelector": "26121ff0",
|
||||||
"id": 25,
|
"id": 21,
|
||||||
"implemented": true,
|
"implemented": true,
|
||||||
"kind": "function",
|
"kind": "function",
|
||||||
"modifiers": [],
|
"modifiers": [],
|
||||||
@ -222,73 +198,49 @@
|
|||||||
"nodeType": "FunctionDefinition",
|
"nodeType": "FunctionDefinition",
|
||||||
"overrides":
|
"overrides":
|
||||||
{
|
{
|
||||||
"id": 22,
|
"id": 18,
|
||||||
"nodeType": "OverrideSpecifier",
|
"nodeType": "OverrideSpecifier",
|
||||||
"overrides":
|
"overrides":
|
||||||
[
|
[
|
||||||
{
|
{
|
||||||
"id": 19,
|
"id": 16,
|
||||||
"nodeType": "UserDefinedTypeName",
|
"name": "A",
|
||||||
"pathNode":
|
"nodeType": "IdentifierPath",
|
||||||
{
|
|
||||||
"id": 18,
|
|
||||||
"name": "A",
|
|
||||||
"nodeType": "IdentifierPath",
|
|
||||||
"referencedDeclaration": 5,
|
|
||||||
"src": "154:1:1"
|
|
||||||
},
|
|
||||||
"referencedDeclaration": 5,
|
"referencedDeclaration": 5,
|
||||||
"src": "154:1:1",
|
"src": "154:1:1"
|
||||||
"typeDescriptions":
|
|
||||||
{
|
|
||||||
"typeIdentifier": "t_contract$_A_$5",
|
|
||||||
"typeString": "contract A"
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"id": 21,
|
"id": 17,
|
||||||
"nodeType": "UserDefinedTypeName",
|
"name": "B",
|
||||||
"pathNode":
|
"nodeType": "IdentifierPath",
|
||||||
{
|
|
||||||
"id": 20,
|
|
||||||
"name": "B",
|
|
||||||
"nodeType": "IdentifierPath",
|
|
||||||
"referencedDeclaration": 10,
|
|
||||||
"src": "157:1:1"
|
|
||||||
},
|
|
||||||
"referencedDeclaration": 10,
|
"referencedDeclaration": 10,
|
||||||
"src": "157:1:1",
|
"src": "157:1:1"
|
||||||
"typeDescriptions":
|
|
||||||
{
|
|
||||||
"typeIdentifier": "t_contract$_B_$10",
|
|
||||||
"typeString": "contract B"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"src": "145:14:1"
|
"src": "145:14:1"
|
||||||
},
|
},
|
||||||
"parameters":
|
"parameters":
|
||||||
{
|
{
|
||||||
"id": 17,
|
"id": 15,
|
||||||
"nodeType": "ParameterList",
|
"nodeType": "ParameterList",
|
||||||
"parameters": [],
|
"parameters": [],
|
||||||
"src": "135:2:1"
|
"src": "135:2:1"
|
||||||
},
|
},
|
||||||
"returnParameters":
|
"returnParameters":
|
||||||
{
|
{
|
||||||
"id": 23,
|
"id": 19,
|
||||||
"nodeType": "ParameterList",
|
"nodeType": "ParameterList",
|
||||||
"parameters": [],
|
"parameters": [],
|
||||||
"src": "160:0:1"
|
"src": "160:0:1"
|
||||||
},
|
},
|
||||||
"scope": 26,
|
"scope": 22,
|
||||||
"src": "125:37:1",
|
"src": "125:37:1",
|
||||||
"stateMutability": "nonpayable",
|
"stateMutability": "nonpayable",
|
||||||
"virtual": false,
|
"virtual": false,
|
||||||
"visibility": "public"
|
"visibility": "public"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"scope": 27,
|
"scope": 23,
|
||||||
"src": "100:64:1"
|
"src": "100:64:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
@ -14,7 +14,7 @@
|
|||||||
],
|
],
|
||||||
"C":
|
"C":
|
||||||
[
|
[
|
||||||
26
|
22
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@ -39,7 +39,7 @@
|
|||||||
5
|
5
|
||||||
],
|
],
|
||||||
"name": "A",
|
"name": "A",
|
||||||
"scope": 27
|
"scope": 23
|
||||||
},
|
},
|
||||||
"children":
|
"children":
|
||||||
[
|
[
|
||||||
@ -130,7 +130,7 @@
|
|||||||
10
|
10
|
||||||
],
|
],
|
||||||
"name": "B",
|
"name": "B",
|
||||||
"scope": 27
|
"scope": 23
|
||||||
},
|
},
|
||||||
"children":
|
"children":
|
||||||
[
|
[
|
||||||
@ -215,12 +215,12 @@
|
|||||||
"fullyImplemented": true,
|
"fullyImplemented": true,
|
||||||
"linearizedBaseContracts":
|
"linearizedBaseContracts":
|
||||||
[
|
[
|
||||||
26,
|
22,
|
||||||
10,
|
10,
|
||||||
5
|
5
|
||||||
],
|
],
|
||||||
"name": "C",
|
"name": "C",
|
||||||
"scope": 27
|
"scope": 23
|
||||||
},
|
},
|
||||||
"children":
|
"children":
|
||||||
[
|
[
|
||||||
@ -231,28 +231,15 @@
|
|||||||
{
|
{
|
||||||
"attributes":
|
"attributes":
|
||||||
{
|
{
|
||||||
"referencedDeclaration": 5,
|
"name": "A",
|
||||||
"type": "contract A"
|
"referencedDeclaration": 5
|
||||||
},
|
},
|
||||||
"children":
|
"id": 11,
|
||||||
[
|
"name": "IdentifierPath",
|
||||||
{
|
|
||||||
"attributes":
|
|
||||||
{
|
|
||||||
"name": "A",
|
|
||||||
"referencedDeclaration": 5
|
|
||||||
},
|
|
||||||
"id": 11,
|
|
||||||
"name": "IdentifierPath",
|
|
||||||
"src": "114:1:1"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"id": 12,
|
|
||||||
"name": "UserDefinedTypeName",
|
|
||||||
"src": "114:1:1"
|
"src": "114:1:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 13,
|
"id": 12,
|
||||||
"name": "InheritanceSpecifier",
|
"name": "InheritanceSpecifier",
|
||||||
"src": "114:1:1"
|
"src": "114:1:1"
|
||||||
},
|
},
|
||||||
@ -263,28 +250,15 @@
|
|||||||
{
|
{
|
||||||
"attributes":
|
"attributes":
|
||||||
{
|
{
|
||||||
"referencedDeclaration": 10,
|
"name": "B",
|
||||||
"type": "contract B"
|
"referencedDeclaration": 10
|
||||||
},
|
},
|
||||||
"children":
|
"id": 13,
|
||||||
[
|
"name": "IdentifierPath",
|
||||||
{
|
|
||||||
"attributes":
|
|
||||||
{
|
|
||||||
"name": "B",
|
|
||||||
"referencedDeclaration": 10
|
|
||||||
},
|
|
||||||
"id": 14,
|
|
||||||
"name": "IdentifierPath",
|
|
||||||
"src": "117:1:1"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"id": 15,
|
|
||||||
"name": "UserDefinedTypeName",
|
|
||||||
"src": "117:1:1"
|
"src": "117:1:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 16,
|
"id": 14,
|
||||||
"name": "InheritanceSpecifier",
|
"name": "InheritanceSpecifier",
|
||||||
"src": "117:1:1"
|
"src": "117:1:1"
|
||||||
},
|
},
|
||||||
@ -305,7 +279,7 @@
|
|||||||
null
|
null
|
||||||
],
|
],
|
||||||
"name": "f",
|
"name": "f",
|
||||||
"scope": 26,
|
"scope": 22,
|
||||||
"stateMutability": "nonpayable",
|
"stateMutability": "nonpayable",
|
||||||
"virtual": false,
|
"virtual": false,
|
||||||
"visibility": "public"
|
"visibility": "public"
|
||||||
@ -318,51 +292,25 @@
|
|||||||
{
|
{
|
||||||
"attributes":
|
"attributes":
|
||||||
{
|
{
|
||||||
"referencedDeclaration": 5,
|
"name": "A",
|
||||||
"type": "contract A"
|
"referencedDeclaration": 5
|
||||||
},
|
},
|
||||||
"children":
|
"id": 16,
|
||||||
[
|
"name": "IdentifierPath",
|
||||||
{
|
|
||||||
"attributes":
|
|
||||||
{
|
|
||||||
"name": "A",
|
|
||||||
"referencedDeclaration": 5
|
|
||||||
},
|
|
||||||
"id": 18,
|
|
||||||
"name": "IdentifierPath",
|
|
||||||
"src": "154:1:1"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"id": 19,
|
|
||||||
"name": "UserDefinedTypeName",
|
|
||||||
"src": "154:1:1"
|
"src": "154:1:1"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"attributes":
|
"attributes":
|
||||||
{
|
{
|
||||||
"referencedDeclaration": 10,
|
"name": "B",
|
||||||
"type": "contract B"
|
"referencedDeclaration": 10
|
||||||
},
|
},
|
||||||
"children":
|
"id": 17,
|
||||||
[
|
"name": "IdentifierPath",
|
||||||
{
|
|
||||||
"attributes":
|
|
||||||
{
|
|
||||||
"name": "B",
|
|
||||||
"referencedDeclaration": 10
|
|
||||||
},
|
|
||||||
"id": 20,
|
|
||||||
"name": "IdentifierPath",
|
|
||||||
"src": "157:1:1"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"id": 21,
|
|
||||||
"name": "UserDefinedTypeName",
|
|
||||||
"src": "157:1:1"
|
"src": "157:1:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 22,
|
"id": 18,
|
||||||
"name": "OverrideSpecifier",
|
"name": "OverrideSpecifier",
|
||||||
"src": "145:14:1"
|
"src": "145:14:1"
|
||||||
},
|
},
|
||||||
@ -375,7 +323,7 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"children": [],
|
"children": [],
|
||||||
"id": 17,
|
"id": 15,
|
||||||
"name": "ParameterList",
|
"name": "ParameterList",
|
||||||
"src": "135:2:1"
|
"src": "135:2:1"
|
||||||
},
|
},
|
||||||
@ -388,7 +336,7 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"children": [],
|
"children": [],
|
||||||
"id": 23,
|
"id": 19,
|
||||||
"name": "ParameterList",
|
"name": "ParameterList",
|
||||||
"src": "160:0:1"
|
"src": "160:0:1"
|
||||||
},
|
},
|
||||||
@ -401,22 +349,22 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"children": [],
|
"children": [],
|
||||||
"id": 24,
|
"id": 20,
|
||||||
"name": "Block",
|
"name": "Block",
|
||||||
"src": "160:2:1"
|
"src": "160:2:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 25,
|
"id": 21,
|
||||||
"name": "FunctionDefinition",
|
"name": "FunctionDefinition",
|
||||||
"src": "125:37:1"
|
"src": "125:37:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 26,
|
"id": 22,
|
||||||
"name": "ContractDefinition",
|
"name": "ContractDefinition",
|
||||||
"src": "100:64:1"
|
"src": "100:64:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 27,
|
"id": 23,
|
||||||
"name": "SourceUnit",
|
"name": "SourceUnit",
|
||||||
"src": "0:165:1"
|
"src": "0:165:1"
|
||||||
}
|
}
|
||||||
|
@ -105,9 +105,8 @@
|
|||||||
{
|
{
|
||||||
"id": 11,
|
"id": 11,
|
||||||
"name": "A",
|
"name": "A",
|
||||||
"nodeType": "UserDefinedTypeName",
|
"nodeType": "IdentifierPath",
|
||||||
"src": "114:1:1",
|
"src": "114:1:1"
|
||||||
"typeDescriptions": {}
|
|
||||||
},
|
},
|
||||||
"id": 12,
|
"id": 12,
|
||||||
"nodeType": "InheritanceSpecifier",
|
"nodeType": "InheritanceSpecifier",
|
||||||
@ -118,9 +117,8 @@
|
|||||||
{
|
{
|
||||||
"id": 13,
|
"id": 13,
|
||||||
"name": "B",
|
"name": "B",
|
||||||
"nodeType": "UserDefinedTypeName",
|
"nodeType": "IdentifierPath",
|
||||||
"src": "117:1:1",
|
"src": "117:1:1"
|
||||||
"typeDescriptions": {}
|
|
||||||
},
|
},
|
||||||
"id": 14,
|
"id": 14,
|
||||||
"nodeType": "InheritanceSpecifier",
|
"nodeType": "InheritanceSpecifier",
|
||||||
@ -157,16 +155,14 @@
|
|||||||
{
|
{
|
||||||
"id": 16,
|
"id": 16,
|
||||||
"name": "A",
|
"name": "A",
|
||||||
"nodeType": "UserDefinedTypeName",
|
"nodeType": "IdentifierPath",
|
||||||
"src": "154:1:1",
|
"src": "154:1:1"
|
||||||
"typeDescriptions": {}
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"id": 17,
|
"id": 17,
|
||||||
"name": "B",
|
"name": "B",
|
||||||
"nodeType": "UserDefinedTypeName",
|
"nodeType": "IdentifierPath",
|
||||||
"src": "157:1:1",
|
"src": "157:1:1"
|
||||||
"typeDescriptions": {}
|
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"src": "145:14:1"
|
"src": "145:14:1"
|
||||||
|
@ -4,14 +4,14 @@
|
|||||||
{
|
{
|
||||||
"C":
|
"C":
|
||||||
[
|
[
|
||||||
6
|
5
|
||||||
],
|
],
|
||||||
"L":
|
"L":
|
||||||
[
|
[
|
||||||
1
|
1
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"id": 7,
|
"id": 6,
|
||||||
"nodeType": "SourceUnit",
|
"nodeType": "SourceUnit",
|
||||||
"nodes":
|
"nodes":
|
||||||
[
|
[
|
||||||
@ -29,7 +29,7 @@
|
|||||||
"name": "L",
|
"name": "L",
|
||||||
"nodeType": "ContractDefinition",
|
"nodeType": "ContractDefinition",
|
||||||
"nodes": [],
|
"nodes": [],
|
||||||
"scope": 7,
|
"scope": 6,
|
||||||
"src": "0:12:1"
|
"src": "0:12:1"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -38,42 +38,30 @@
|
|||||||
"contractDependencies": [],
|
"contractDependencies": [],
|
||||||
"contractKind": "contract",
|
"contractKind": "contract",
|
||||||
"fullyImplemented": true,
|
"fullyImplemented": true,
|
||||||
"id": 6,
|
"id": 5,
|
||||||
"linearizedBaseContracts":
|
"linearizedBaseContracts":
|
||||||
[
|
[
|
||||||
6
|
5
|
||||||
],
|
],
|
||||||
"name": "C",
|
"name": "C",
|
||||||
"nodeType": "ContractDefinition",
|
"nodeType": "ContractDefinition",
|
||||||
"nodes":
|
"nodes":
|
||||||
[
|
[
|
||||||
{
|
{
|
||||||
"id": 5,
|
"id": 4,
|
||||||
"libraryName":
|
"libraryName":
|
||||||
{
|
{
|
||||||
"id": 3,
|
"id": 2,
|
||||||
"nodeType": "UserDefinedTypeName",
|
"name": "L",
|
||||||
"pathNode":
|
"nodeType": "IdentifierPath",
|
||||||
{
|
|
||||||
"id": 2,
|
|
||||||
"name": "L",
|
|
||||||
"nodeType": "IdentifierPath",
|
|
||||||
"referencedDeclaration": 1,
|
|
||||||
"src": "32:1:1"
|
|
||||||
},
|
|
||||||
"referencedDeclaration": 1,
|
"referencedDeclaration": 1,
|
||||||
"src": "32:1:1",
|
"src": "32:1:1"
|
||||||
"typeDescriptions":
|
|
||||||
{
|
|
||||||
"typeIdentifier": "t_contract$_L_$1",
|
|
||||||
"typeString": "library L"
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
"nodeType": "UsingForDirective",
|
"nodeType": "UsingForDirective",
|
||||||
"src": "26:17:1",
|
"src": "26:17:1",
|
||||||
"typeName":
|
"typeName":
|
||||||
{
|
{
|
||||||
"id": 4,
|
"id": 3,
|
||||||
"name": "uint",
|
"name": "uint",
|
||||||
"nodeType": "ElementaryTypeName",
|
"nodeType": "ElementaryTypeName",
|
||||||
"src": "38:4:1",
|
"src": "38:4:1",
|
||||||
@ -85,7 +73,7 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"scope": 7,
|
"scope": 6,
|
||||||
"src": "13:32:1"
|
"src": "13:32:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
{
|
{
|
||||||
"C":
|
"C":
|
||||||
[
|
[
|
||||||
6
|
5
|
||||||
],
|
],
|
||||||
"L":
|
"L":
|
||||||
[
|
[
|
||||||
@ -39,7 +39,7 @@
|
|||||||
[
|
[
|
||||||
null
|
null
|
||||||
],
|
],
|
||||||
"scope": 7
|
"scope": 6
|
||||||
},
|
},
|
||||||
"id": 1,
|
"id": 1,
|
||||||
"name": "ContractDefinition",
|
"name": "ContractDefinition",
|
||||||
@ -61,10 +61,10 @@
|
|||||||
"fullyImplemented": true,
|
"fullyImplemented": true,
|
||||||
"linearizedBaseContracts":
|
"linearizedBaseContracts":
|
||||||
[
|
[
|
||||||
6
|
5
|
||||||
],
|
],
|
||||||
"name": "C",
|
"name": "C",
|
||||||
"scope": 7
|
"scope": 6
|
||||||
},
|
},
|
||||||
"children":
|
"children":
|
||||||
[
|
[
|
||||||
@ -74,24 +74,11 @@
|
|||||||
{
|
{
|
||||||
"attributes":
|
"attributes":
|
||||||
{
|
{
|
||||||
"referencedDeclaration": 1,
|
"name": "L",
|
||||||
"type": "library L"
|
"referencedDeclaration": 1
|
||||||
},
|
},
|
||||||
"children":
|
"id": 2,
|
||||||
[
|
"name": "IdentifierPath",
|
||||||
{
|
|
||||||
"attributes":
|
|
||||||
{
|
|
||||||
"name": "L",
|
|
||||||
"referencedDeclaration": 1
|
|
||||||
},
|
|
||||||
"id": 2,
|
|
||||||
"name": "IdentifierPath",
|
|
||||||
"src": "32:1:1"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"id": 3,
|
|
||||||
"name": "UserDefinedTypeName",
|
|
||||||
"src": "32:1:1"
|
"src": "32:1:1"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -100,22 +87,22 @@
|
|||||||
"name": "uint",
|
"name": "uint",
|
||||||
"type": "uint256"
|
"type": "uint256"
|
||||||
},
|
},
|
||||||
"id": 4,
|
"id": 3,
|
||||||
"name": "ElementaryTypeName",
|
"name": "ElementaryTypeName",
|
||||||
"src": "38:4:1"
|
"src": "38:4:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 5,
|
"id": 4,
|
||||||
"name": "UsingForDirective",
|
"name": "UsingForDirective",
|
||||||
"src": "26:17:1"
|
"src": "26:17:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 6,
|
"id": 5,
|
||||||
"name": "ContractDefinition",
|
"name": "ContractDefinition",
|
||||||
"src": "13:32:1"
|
"src": "13:32:1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": 7,
|
"id": 6,
|
||||||
"name": "SourceUnit",
|
"name": "SourceUnit",
|
||||||
"src": "0:46:1"
|
"src": "0:46:1"
|
||||||
}
|
}
|
||||||
|
@ -31,9 +31,8 @@
|
|||||||
{
|
{
|
||||||
"id": 2,
|
"id": 2,
|
||||||
"name": "L",
|
"name": "L",
|
||||||
"nodeType": "UserDefinedTypeName",
|
"nodeType": "IdentifierPath",
|
||||||
"src": "32:1:1",
|
"src": "32:1:1"
|
||||||
"typeDescriptions": {}
|
|
||||||
},
|
},
|
||||||
"nodeType": "UsingForDirective",
|
"nodeType": "UsingForDirective",
|
||||||
"src": "26:17:1",
|
"src": "26:17:1",
|
||||||
|
@ -0,0 +1,25 @@
|
|||||||
|
==== Source: A ====
|
||||||
|
contract C {
|
||||||
|
int private x;
|
||||||
|
constructor (int p) public { x = p; }
|
||||||
|
function getX() public returns (int) { return x; }
|
||||||
|
}
|
||||||
|
==== Source: B ====
|
||||||
|
import "A" as M;
|
||||||
|
|
||||||
|
contract D is M.C {
|
||||||
|
constructor (int p) M.C(p) public {}
|
||||||
|
}
|
||||||
|
|
||||||
|
contract A {
|
||||||
|
function g(int p) public returns (int) {
|
||||||
|
D d = new D(p);
|
||||||
|
return d.getX();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// ====
|
||||||
|
// compileViaYul: also
|
||||||
|
// ----
|
||||||
|
// g(int256): -1 -> -1
|
||||||
|
// g(int256): 10 -> 10
|
@ -17,3 +17,4 @@ contract C
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
// ----
|
// ----
|
||||||
|
// Warning 4661: (297-321): BMC: Assertion violation happens here.
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
function fun() someModifier {
|
function fun() someModifier {
|
||||||
}
|
}
|
||||||
// ----
|
// ----
|
||||||
// DeclarationError 7576: (15-27): Undeclared identifier.
|
// DeclarationError 7920: (15-27): Identifier not found or not unique.
|
||||||
|
@ -6,4 +6,4 @@ function fun() C.someModifier {
|
|||||||
|
|
||||||
}
|
}
|
||||||
// ----
|
// ----
|
||||||
// ParserError 2314: (65-66): Expected '{' but got '.'
|
// SyntaxError 5811: (49-83): Free functions cannot have modifiers.
|
||||||
|
@ -4,4 +4,4 @@ contract C {
|
|||||||
}
|
}
|
||||||
// ----
|
// ----
|
||||||
// SyntaxError 2668: (83-99): Functions without implementation cannot have modifiers.
|
// SyntaxError 2668: (83-99): Functions without implementation cannot have modifiers.
|
||||||
// DeclarationError 7576: (97-98): Undeclared identifier.
|
// DeclarationError 7920: (97-98): Identifier not found or not unique.
|
||||||
|
Loading…
Reference in New Issue
Block a user