blob: 054cb34f63020dd5eea43d24cf072906a440f96c (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
|
contract test {
enum Paper { Up, Down, Left, Right }
enum Ground { North, South, West, East }
function test() public {
Ground(Paper.Up);
}
}
// ----
// Warning: (106-162): Defining constructors as functions with the same name as the contract is deprecated. Use "constructor(...) { ... }" instead.
// TypeError: (139-155): Explicit type conversion not allowed from "enum test.Paper" to "enum test.Ground".
|