aboutsummaryrefslogtreecommitdiffstats
path: root/test/libsolidity/syntaxTests/nameAndTypeResolution/132_enum_to_enum_conversion_is_not_okay.sol
blob: 5b9ba813a53783dbf23bd5e7bb06d41874948211 (plain) (blame)
1
2
3
4
5
6
7
8
9
contract test {
    enum Paper { Up, Down, Left, Right }
    enum Ground { North, South, West, East }
    constructor() public {
        Ground(Paper.Up);
    }
}
// ----
// TypeError: (137-153): Explicit type conversion not allowed from "enum test.Paper" to "enum test.Ground".