diff options
| author | chriseth <chris@ethereum.org> | 2018-12-03 19:41:25 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2018-12-03 19:41:25 +0800 |
| commit | eed353a367ebae2a94ef1a760fa5494c2cea4015 (patch) | |
| tree | 9c66fd2f68cc6e65e08d952a2b177537b3603190 /test/libsolidity | |
| parent | 0df641fea1bbcc531f2ec668d2fb249065deaea3 (diff) | |
| parent | 82f5763e7afa498f891e9d41b30278c4482ddb8b (diff) | |
| download | dexon-solidity-eed353a367ebae2a94ef1a760fa5494c2cea4015.tar dexon-solidity-eed353a367ebae2a94ef1a760fa5494c2cea4015.tar.gz dexon-solidity-eed353a367ebae2a94ef1a760fa5494c2cea4015.tar.bz2 dexon-solidity-eed353a367ebae2a94ef1a760fa5494c2cea4015.tar.lz dexon-solidity-eed353a367ebae2a94ef1a760fa5494c2cea4015.tar.xz dexon-solidity-eed353a367ebae2a94ef1a760fa5494c2cea4015.tar.zst dexon-solidity-eed353a367ebae2a94ef1a760fa5494c2cea4015.zip | |
Merge pull request #5558 from anurag-git/issue_5130
Fix internal compiler error for unimplemented base contract function.
Diffstat (limited to 'test/libsolidity')
| -rw-r--r-- | test/libsolidity/syntaxTests/unimplemented_super_function.sol | 8 | ||||
| -rw-r--r-- | test/libsolidity/syntaxTests/unimplemented_super_function_derived.sol | 12 |
2 files changed, 20 insertions, 0 deletions
diff --git a/test/libsolidity/syntaxTests/unimplemented_super_function.sol b/test/libsolidity/syntaxTests/unimplemented_super_function.sol new file mode 100644 index 00000000..356727ae --- /dev/null +++ b/test/libsolidity/syntaxTests/unimplemented_super_function.sol @@ -0,0 +1,8 @@ +contract a { + function f() public; +} +contract b is a { + function f() public { super.f(); } +} +// ---- +// TypeError: (84-91): Member "f" not found or not visible after argument-dependent lookup in contract super b. diff --git a/test/libsolidity/syntaxTests/unimplemented_super_function_derived.sol b/test/libsolidity/syntaxTests/unimplemented_super_function_derived.sol new file mode 100644 index 00000000..88acbdf0 --- /dev/null +++ b/test/libsolidity/syntaxTests/unimplemented_super_function_derived.sol @@ -0,0 +1,12 @@ +contract a { + function f() public; +} +contract b is a { + function f() public { super.f(); } +} +contract c is a,b { + // No error here. + function f() public { super.f(); } +} +// ---- +// TypeError: (84-91): Member "f" not found or not visible after argument-dependent lookup in contract super b. |
