Skip to content

Commit

Permalink
fix: Change description of temporary limitations (#69)
Browse files Browse the repository at this point in the history
* Change description of temporary limitations

* Update temp-limits.md

* Update temp-limits.md
  • Loading branch information
StanislavBreadless committed Jun 24, 2022
1 parent b73cd52 commit 2b3b78a
Showing 1 changed file with 11 additions and 8 deletions.
19 changes: 11 additions & 8 deletions docs/dev/zksync-v2/temp-limits.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

::: tip Call for feedback

As we add new features, this page is constantly updated. Most of the issues listed here (especially around the opcodes) will be resolved by the time of the mainnet launch.
As we add new features, this page is constantly updated.

If any of these block you, let us know on our [discord](https://discord.gg/px2aR7w), so we can prioritize accordingly.

Expand All @@ -16,7 +16,13 @@ However, if a library contains at least one `public` or `external` method, it is

## Unsupported opcodes

#### Returning constant value
- `SELFDESTRUCT` (it’s considered harmful and there are calls to deactivate it on L1).
- `EXTCODECOPY` (it can be implemented if needed, but we skip it for now because zkEVM opcodes are not identical to EVM ones anyway).
- `CALLCODE` (deprecated on Ethereum in favor of `DELEGATECALL`).

## Temporarily simulated by constant values

These opcodes will be supported by the time of the mainnet launch.

- `block.gaslimit` always returns `2^32-1`.
- `MSIZE` always returns `2^16`.
Expand All @@ -25,12 +31,9 @@ However, if a library contains at least one `public` or `external` method, it is
- `GASPRICE` (`tx.gasprice`) always returns `0`.
- `CHAINID` (`chain_id`) always returns `0`.
- `BLOCKHASH` (`tx.blockhash`) always returns `0`.
- `DIFFICULTY` (`block.difficulty`) always returns `0`.
- `PC` always returns `0`.
- `COINBASE` (`block.coinbase`) always returns `0`.

#### NOOP
## Ignored by the compiler

- `EXTCODECOPY`
- `SELFDESTRUCT` (`selfdestruct(addr)`)
- `CALLCODE` (`callcode`)
- `DIFFICULTY` (`block.difficulty`) always returns `0` (zkSync does not have proof of work consensus).
- `PC` always returns `0` (we can technically support it, but most likely its use-cases are very specific for the EVM, so to avoid confusion it was decided not to; also, since solidity 0.7.0, it is non-accessible in yul and solidity).

0 comments on commit 2b3b78a

Please sign in to comment.