solidity/test/libsolidity/syntaxTests/nameAndTypeResolution/194_negative_integers_to_unsigned.sol

6 lines
151 B
Solidity
Raw Normal View History

contract test {
uint8 public x = -1;
}
// ----
// TypeError 7407: (37-39): Type int_const -1 is not implicitly convertible to expected type uint8.