diff options
author | Federico Bond <federicobond@gmail.com> | 2017-07-18 06:12:34 +0800 |
---|---|---|
committer | Alex Beregszaszi <alex@rtfs.hu> | 2017-08-12 05:45:25 +0800 |
commit | ff5bb54e3c19bedfadd06dd60f032fd7cdc55389 (patch) | |
tree | 8bbcfaedd172fa7cbbe34165d4dd71fdfb86f739 /libsolidity/ast/AST.cpp | |
parent | a5ceaac8df80f89112bb4d7bbfd9da165d370aa3 (diff) | |
download | dexon-solidity-ff5bb54e3c19bedfadd06dd60f032fd7cdc55389.tar.gz dexon-solidity-ff5bb54e3c19bedfadd06dd60f032fd7cdc55389.tar.zst dexon-solidity-ff5bb54e3c19bedfadd06dd60f032fd7cdc55389.zip |
Use fully qualified name of super in message
Diffstat (limited to 'libsolidity/ast/AST.cpp')
-rw-r--r-- | libsolidity/ast/AST.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/libsolidity/ast/AST.cpp b/libsolidity/ast/AST.cpp index 1d68231e..e173237e 100644 --- a/libsolidity/ast/AST.cpp +++ b/libsolidity/ast/AST.cpp @@ -371,6 +371,15 @@ string FunctionDefinition::externalSignature() const return FunctionType(*this).externalSignature(); } +string FunctionDefinition::fullyQualifiedName() const +{ + auto const* contract = dynamic_cast<ContractDefinition const*>(scope()); + solAssert(contract, "Enclosing scope of function definition was not set."); + + auto fname = name().empty() ? "<fallback>" : name(); + return sourceUnitName() + ":" + contract->name() + "." + fname; +} + FunctionDefinitionAnnotation& FunctionDefinition::annotation() const { if (!m_annotation) |