solidity/test/libsolidity/syntaxTests/nameAndTypeResolution/316_fixed_type_invalid_implicit_conversion_lost_data.sol

8 lines
271 B
Solidity
Raw Normal View History

contract test {
function f() public {
ufixed256x1 a = 1/3; a;
}
}
// ----
// TypeError 4486: (50-69): Type rational_const 1 / 3 is not implicitly convertible to expected type ufixed256x1. Try converting to type ufixed256x77 or use an explicit conversion.