solidity/test/libsolidity/smtCheckerTests/typecast/cast_larger_2.sol

14 lines
319 B
Solidity
Raw Normal View History

2018-12-20 12:20:07 +00:00
pragma experimental SMTChecker;
contract C
{
function f() public pure {
uint16 a = 0x1234;
uint32 b = uint32(a); // b will be 0x00001234 now
// This is correct (left padding).
assert(a == b);
}
}
// ----
// Warning 5084: (108-117): Type conversion is not yet fully supported and might yield false positives.