diff options
Diffstat (limited to 'test/libsolidity/syntaxTests/nameAndTypeResolution/073_state_variable_member_of_wrong_class2.sol')
-rw-r--r-- | test/libsolidity/syntaxTests/nameAndTypeResolution/073_state_variable_member_of_wrong_class2.sol | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/test/libsolidity/syntaxTests/nameAndTypeResolution/073_state_variable_member_of_wrong_class2.sol b/test/libsolidity/syntaxTests/nameAndTypeResolution/073_state_variable_member_of_wrong_class2.sol new file mode 100644 index 00000000..9a0ee8a3 --- /dev/null +++ b/test/libsolidity/syntaxTests/nameAndTypeResolution/073_state_variable_member_of_wrong_class2.sol @@ -0,0 +1,12 @@ +contract Parent1 { + uint256 internal m_aMember1; +} +contract Parent2 is Parent1 { + uint256 internal m_aMember2; +} +contract Child is Parent2 { + function foo() public returns (uint256) { return Child.m_aMember2; } + uint256 public m_aMember3; +} +// ---- +// TypeError: (200-216): Member "m_aMember2" not found or not visible after argument-dependent lookup in type(contract Child) |