Skip to content
This repository has been archived by the owner on Oct 3, 2024. It is now read-only.

Commit

Permalink
chore: solc zkvm support (#878)
Browse files Browse the repository at this point in the history
  • Loading branch information
kiriyaga-txfusion authored Jan 24, 2024
1 parent 8bc55b4 commit 5441255
Showing 1 changed file with 28 additions and 0 deletions.
28 changes: 28 additions & 0 deletions docs/build/tooling/hardhat/hardhat-zksync-solc.md
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,34 @@ For Solidity versions older than 0.8, only this compilation mode is available an

:::

### zkSync Era Solidity compiler

Due to [the identified limitations](https://docs.zksync.io/zk-stack/components/compiler/toolchain/solidity.html#limitations) of the [upstream Solidity compiler](https://github.com/ethereum/solidity), our team has developed [a new edition](https://github.com/matter-labs/era-solidity) of the compiler, which effectively addresses and resolves these constraints.

For usage of EraVM compiler, `eraVersion` should be added inside `solidity` property in the `hardhat.config.ts` file:

```typescript
solidity: {
version: "0.8.17",
eraVersion: "1.0.0" //optional. Compile contracts with EraVM compiler
},

```

- `eraVersion` - (optional) field used to specify version of EraVM compiler

::: warning eraVersion usage

Using latest as the field value is not supported. Instead, the eraVersion field must be filled with a specific version.

:::

::: warning EraVM compiler usage

To use the EraVM compiler, the zksolc compiler version must be equal to or greater than 1.3.22.

:::

### Network configuration

Configure the `zksync` parameter in the networks to enable the zksolc compiler:
Expand Down

0 comments on commit 5441255

Please sign in to comment.