aboutsummaryrefslogtreecommitdiffstats
path: root/test/libsolidity/syntaxTests/tight_packing_literals_fine.sol
diff options
context:
space:
mode:
authorchriseth <chris@ethereum.org>2018-04-13 02:55:03 +0800
committerGitHub <noreply@github.com>2018-04-13 02:55:03 +0800
commit44416d1ac65b2cfae4bb15d39bc84b1a78211baa (patch)
tree7b8ee302e1c4f0604f29d2fe21a2d0393cc60d11 /test/libsolidity/syntaxTests/tight_packing_literals_fine.sol
parent7453ff0f3a94ce4ddce55cdbb77146dd75a01e1c (diff)
parent75b88286667690ffb4a5e079665ed8b70bcaeb87 (diff)
downloaddexon-solidity-44416d1ac65b2cfae4bb15d39bc84b1a78211baa.tar.gz
dexon-solidity-44416d1ac65b2cfae4bb15d39bc84b1a78211baa.tar.zst
dexon-solidity-44416d1ac65b2cfae4bb15d39bc84b1a78211baa.zip
Merge pull request #2980 from ethereum/abi-api
Add abi.encode and abi.encodePacked
Diffstat (limited to 'test/libsolidity/syntaxTests/tight_packing_literals_fine.sol')
-rw-r--r--test/libsolidity/syntaxTests/tight_packing_literals_fine.sol11
1 files changed, 11 insertions, 0 deletions
diff --git a/test/libsolidity/syntaxTests/tight_packing_literals_fine.sol b/test/libsolidity/syntaxTests/tight_packing_literals_fine.sol
new file mode 100644
index 00000000..46407f71
--- /dev/null
+++ b/test/libsolidity/syntaxTests/tight_packing_literals_fine.sol
@@ -0,0 +1,11 @@
+contract C {
+ function f() pure public returns (bytes32) {
+ return keccak256(uint8(1));
+ }
+ function g() pure public returns (bytes) {
+ return abi.encode(1);
+ }
+ function h() pure public returns (bytes) {
+ return abi.encodePacked(uint8(1));
+ }
+}