Skip to content

Commit

Permalink
chore(docstrings): added doc string comments where missing
Browse files Browse the repository at this point in the history
  • Loading branch information
koloz193 committed Jan 24, 2024
1 parent abcbaf3 commit 3ee0491
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 0 deletions.
11 changes: 11 additions & 0 deletions l1-contracts/contracts/zksync/interfaces/IExecutor.sol
Original file line number Diff line number Diff line change
Expand Up @@ -155,18 +155,29 @@ interface IExecutor is IBase {
function revertBatches(uint256 _newLastBatch) external;

/// @notice Event emitted when a batch is committed
/// @param batchNumber Number of the batch committed
/// @param batchHash Hash of the L2 batch
/// @param commitment Verified input for the zkSync circuit
/// @dev It has the name "BlockCommit" and not "BatchCommit" due to backward compatibility considerations
event BlockCommit(uint256 indexed batchNumber, bytes32 indexed batchHash, bytes32 indexed commitment);

/// @notice Event emitted when batches are verified
/// @param previousLastVerifiedBatch Batch number of the previous last verified batch
/// @param currentLastVerifiedBatch Batch number of the current last verified batch
/// @dev It has the name "BlocksVerification" and not "BatchesVerification" due to backward compatibility considerations
event BlocksVerification(uint256 indexed previousLastVerifiedBatch, uint256 indexed currentLastVerifiedBatch);

/// @notice Event emitted when a batch is executed
/// @param batchNumber Number of the batch committed
/// @param batchHash Hash of the L2 batch
/// @param commitment Verified input for the zkSync circuit
/// @dev It has the name "BlockExecution" and not "BatchExecution" due to backward compatibility considerations
event BlockExecution(uint256 indexed batchNumber, bytes32 indexed batchHash, bytes32 indexed commitment);

/// @notice Event emitted when batches are reverted
/// @param totalBatchesCommitted Total number of committed batches
/// @param totalBatchesVerified Total number of verified batches
/// @param totalBatchesExecuted Total number of executed batches
/// @dev It has the name "BlocksRevert" and not "BatchesRevert" due to backward compatibility considerations
event BlocksRevert(uint256 totalBatchesCommitted, uint256 totalBatchesVerified, uint256 totalBatchesExecuted);
}
2 changes: 2 additions & 0 deletions system-contracts/contracts/L1Messenger.sol
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,7 @@ contract L1Messenger is IL1Messenger, ISystemContract {
}

/// @notice Public functionality to send messages to L1.
/// @param _message The preimage of the message intended to be sent to L1.
function sendToL1(bytes calldata _message) external override returns (bytes32 hash) {
uint256 gasBeforeMessageHashing = gasleft();
hash = EfficientCall.keccak(_message);
Expand Down Expand Up @@ -156,6 +157,7 @@ contract L1Messenger is IL1Messenger, ISystemContract {
}

/// @dev Can be called only by KnownCodesStorage system contract.
/// @param _bytecodeHash Hash of bytecode being published to L1.
function requestBytecodeL1Publication(
bytes32 _bytecodeHash
) external override onlyCallFrom(address(KNOWN_CODE_STORAGE_CONTRACT)) {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
// SPDX-License-Identifier: MIT
pragma solidity 0.8.20;

/**
* @author Matter Labs
* @custom:security-contact [email protected]
* @notice Interface for contract responsible chunking pubdata into the appropriate size for EIP-4844 blobs.
*/
interface IPubdataChunkPublisher {
/// @notice Chunks pubdata into pieces that can fit into blobs.
/// @param _pubdata The total l2 to l1 pubdata that will be sent via L1 blobs.
Expand Down

0 comments on commit 3ee0491

Please sign in to comment.