From 49e86ff026c258675945d4f6db4580b2e827acc1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pawe=C5=82=20Bylica?= Date: Wed, 31 Jan 2018 17:51:59 +0100 Subject: [PATCH] EIP-145: Add more test cases --- EIPS/eip-145.md | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/EIPS/eip-145.md b/EIPS/eip-145.md index 15fb26ae..094f5282 100644 --- a/EIPS/eip-145.md +++ b/EIPS/eip-145.md @@ -151,6 +151,13 @@ The newly introduced instructions have no effect on bytecode created in the past --- 0x0000000000000000000000000000000000000000000000000000000000000000 ``` +11. ``` + PUSH 0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff + PUSH 0x01 + SHL + --- + 0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe + ``` ### `SHR` (logical shift right) @@ -326,6 +333,27 @@ The newly introduced instructions have no effect on bytecode created in the past --- 0x000000000000000000000000000000000000000000000000000000000000007f ``` +14. ``` + PUSH 0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff + PUSH 0xfe + SAR + --- + 0x0000000000000000000000000000000000000000000000000000000000000001 + ``` +15. ``` + PUSH 0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff + PUSH 0xff + SAR + --- + 0x0000000000000000000000000000000000000000000000000000000000000000 + ``` +16. ``` + PUSH 0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff + PUSH 0x100 + SAR + --- + 0x0000000000000000000000000000000000000000000000000000000000000000 + ``` ## Implementation