Open yarkinwho opened 1 year ago
We have something about this in the docs already (https://docs.eosnetwork.com/evm/miscellaneous/evm-compatibility#push0-opcode) but the issue is that a lot of the defaults for tooling now use v0.8.20
OpenZeppelin contracts is a prime example.
If you npm i @openzeppelin/contracts
without specifying a version, then you will get contracts that are pragma solidity ^0.8.20;
https://github.com/OpenZeppelin/openzeppelin-contracts/blob/master/contracts/token/ERC20/ERC20.sol
Some developers are encountering problems during contract deployment reporting "Bad Instruction" (my guess is the new PUSH0). Set EVM version to Istanbul when compiling the contract can solve the problem (at least for the case I see).
I believe now latest solidity compilers starts to use this new opcode, it's no longer safe to ignore the EVM version settings. We should add something to docs about this.