Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(docstrings): added doc string comments where missing #189

Merged
merged 3 commits into from
Feb 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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 Calculated 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 executed
/// @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 after the revert
/// @param totalBatchesVerified Total number of verified batches after the revert
/// @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);
}
5 changes: 5 additions & 0 deletions system-contracts/contracts/L1Messenger.sol
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,9 @@ contract L1Messenger is IL1Messenger, ISystemContract {
}

/// @notice Sends L2ToL1Log.
/// @param _isService The `isService` flag.
/// @param _key The `key` part of the L2Log.
/// @param _value The `value` part of the L2Log.
/// @dev Can be called only by a system contract.
function sendL2ToL1Log(
bool _isService,
Expand Down Expand Up @@ -109,6 +112,7 @@ contract L1Messenger is IL1Messenger, ISystemContract {
}

/// @notice Public functionality to send messages to L1.
/// @param _message 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 +160,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
Loading