Document revert()

This commit is contained in:
Alex Beregszaszi 2017-02-06 22:47:05 +00:00
parent f3158f92d6
commit 1fcad8b4ab
2 changed files with 4 additions and 0 deletions

View File

@ -2,6 +2,8 @@
Features:
* Add ``assert(condition)``, which throws if condition is false.
* Code generator: Support ``revert()`` to abort with rolling back, but not consuming all gas.
* Inline assembly: Support ``revert`` (EIP140) as an opcode.
* Type system: Support explicit conversion of external function to address.
Bugfixes:

View File

@ -248,6 +248,8 @@ In the grammar, opcodes are represented as pre-defined identifiers.
+-------------------------+------+-----------------------------------------------------------------+
| return(p, s) | `-` | end execution, return data mem[p..(p+s)) |
+-------------------------+------+-----------------------------------------------------------------+
| revert(p, s) | `-` | end execution, revert state changes, return data mem[p..(p+s)) |
+-------------------------+------+-----------------------------------------------------------------+
| selfdestruct(a) | `-` | end execution, destroy current contract and send funds to a |
+-------------------------+------+-----------------------------------------------------------------+
| invalid | `-` | end execution with invalid instruction |