solidity/test/libsolidity/syntaxTests/parsing/mapping_nonelementary_key_2.sol
2022-04-01 23:41:18 -05:00

9 lines
208 B
Solidity

contract c {
struct S {
uint x;
}
mapping(S => uint) data;
}
// ----
// TypeError 7804: (47-48='S'): Only elementary types, user defined value types, contract types or enums are allowed as mapping keys.