mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Syntax test.
This commit is contained in:
parent
5b9da8418d
commit
a717146b00
10
test/libsolidity/syntaxTests/fixed_point/encodepacked.sol
Normal file
10
test/libsolidity/syntaxTests/fixed_point/encodepacked.sol
Normal file
@ -0,0 +1,10 @@
|
||||
contract C {
|
||||
function f() public pure returns (bytes memory) {
|
||||
return abi.encode(
|
||||
1.23,
|
||||
1/3
|
||||
);
|
||||
}
|
||||
}
|
||||
// ----
|
||||
// TypeError 8009: (124-127): Invalid rational number (too large or division by zero).
|
@ -4,4 +4,3 @@ contract C {
|
||||
}
|
||||
}
|
||||
// ----
|
||||
// TypeError 6090: (92-95): Fractional numbers cannot yet be encoded.
|
||||
|
@ -5,4 +5,3 @@ contract C {
|
||||
}
|
||||
}
|
||||
// ----
|
||||
// TypeError 6090: (126-129): Fractional numbers cannot yet be encoded.
|
||||
|
@ -4,5 +4,5 @@ contract C {
|
||||
}
|
||||
}
|
||||
// ----
|
||||
// TypeError 6090: (98-101): Fractional numbers cannot yet be encoded.
|
||||
// TypeError 7279: (98-101): Cannot perform packed encoding for a literal. Please convert it to an explicit type first.
|
||||
// TypeError 7279: (103-104): Cannot perform packed encoding for a literal. Please convert it to an explicit type first.
|
||||
|
@ -5,5 +5,5 @@ contract C {
|
||||
}
|
||||
}
|
||||
// ----
|
||||
// TypeError 6090: (132-135): Fractional numbers cannot yet be encoded.
|
||||
// TypeError 7279: (132-135): Cannot perform packed encoding for a literal. Please convert it to an explicit type first.
|
||||
// TypeError 7279: (137-138): Cannot perform packed encoding for a literal. Please convert it to an explicit type first.
|
||||
|
Loading…
Reference in New Issue
Block a user