solidity/test/libsolidity/syntaxTests/types/encoding_packed_fractional.sol

9 lines
304 B
Solidity
Raw Normal View History

2019-01-17 12:54:31 +00:00
contract C {
function f1() public pure returns (bytes memory) {
return abi.encodePacked(0.1, 1);
}
}
// ----
// TypeError: (98-101): Fractional numbers cannot yet be encoded.
// TypeError: (103-104): Cannot perform packed encoding for a literal. Please convert it to an explicit type first.