Automatically merged updates to draft EIP(s) 2535 (#2979)

Hi, I'm a bot! This change was automatically merged because:

 - It only modifies existing Draft or Last Call EIP(s)
 - The PR was approved or written by at least one author of each modified EIP
 - The build is passing
This commit is contained in:
Nick Mudge 2020-09-14 10:34:58 -04:00 committed by GitHub
parent f203da639c
commit 6b53155bcc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -313,12 +313,12 @@ The `diamondCut` function does nothing if a supplied function selector is alread
After adding/replacing/removing functions the `_calldata` argument is executed with `delegatecall` on `_init`. This execution is done to initialize data or setup or remove anything needed or no longer needed after adding, replacing and/or removing functions.
If the `_init` value is `address(0)` then `_calldata` is executed with `delegatecall` on the diamond itself.
If the `_init` value is `address(0)` then `_calldata` must contain 0 bytes or the transaction reverts.
If the `_init` value is not `address(0)` then `_calldata` must contain more than 0 bytes or the transaction reverts.
If `_init` is `address(0)` and `_calldata` contains 0 bytes then `_calldata` execution is skipped. `_calldata` is not executed and the `diamondCut` call can complete successfully.
If `_init` is not `address(0)` and `_calldata` contains 0 bytes then it is an error and `diamondCut` reverts.
#### DiamondCut Event
The `_diamondCut`, `_init`, and `_calldata` arguments are passed directly to the `DiamondCut` event.