Skip to content

Commit

Permalink
chore: NatSpec
Browse files Browse the repository at this point in the history
  • Loading branch information
Zer0dot committed Oct 16, 2024
1 parent fc6a77c commit 6106d8d
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 8 deletions.
8 changes: 8 additions & 0 deletions src/account/SemiModularAccountBase.sol
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,14 @@ import {SignatureType} from "../helpers/SignatureType.sol";
import {RTCallBuffer, SigCallBuffer, UOCallBuffer} from "../libraries/ExecutionLib.sol";
import {ModularAccountBase} from "./ModularAccountBase.sol";

/// @title SemiModularAccountBase
/// @author Alchemy
///
/// @notice Abstract base contract for the Alchemy Semi-Modular Account variants. Includes fallback signer
/// functionality.
///
/// @dev Inherits ModularAccountBase. Overrides certain functionality from ModularAccountBase, and exposes an
/// internal virtual getter for the fallback signer.
abstract contract SemiModularAccountBase is ModularAccountBase {
using MessageHashUtils for bytes32;
using ModuleEntityLib for ModuleEntity;
Expand Down
7 changes: 4 additions & 3 deletions src/account/SemiModularAccountBytecode.sol
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,11 @@ import {SemiModularAccountBase} from "./SemiModularAccountBase.sol";
/// @title SemiModularAccountBytecode
/// @author Alchemy
///
/// @notice An implementation of a semi-modular account with a fallback that reads the signer from proxy bytecode.
/// @notice An implementation of a semi-modular account which reads the signer from proxy bytecode if it is not
/// disabled and zero in storage.
///
/// @dev This account requires that its proxy is compliant with Solady's LibClone ERC1967WithImmutableArgs
/// bytecode.
/// @dev Inherits SemiModularAccountBase. This account requires that its proxy is compliant with Solady's LibClone
/// ERC1967WithImmutableArgs bytecode with a bytecode-appended address to be used as the fallback signer.
contract SemiModularAccountBytecode is SemiModularAccountBase {
constructor(IEntryPoint anEntryPoint) SemiModularAccountBase(anEntryPoint) {}

Expand Down
8 changes: 5 additions & 3 deletions src/account/SemiModularAccountStorageOnly.sol
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,12 @@ import {SemiModularAccountBase} from "./SemiModularAccountBase.sol";
/// @title SemiModularAccountStorageOnly
/// @author Alchemy
///
/// @notice A basic Semi-Modular Account with an initializer to set the fallback signer in storage.
/// @notice An implementation of a semi-modular account which includes an initializer to set the fallback signer in
/// storage upon initialization.
///
/// @dev Note that the initializer has no access control and should be called via `upgradeToAndCall()`.
/// It's recommended to opt for the variant `SemiModularAccountBytecode` instead for new accounts.
/// @dev Inherits SemiModularAccountBase. Note that the initializer has no access control and should be called via `upgradeToAndCall()`.
/// Use the `SemiModularAccountBytecode` instead for new accounts, this implementation should only be used for
/// account upgrades.
contract SemiModularAccountStorageOnly is SemiModularAccountBase {
constructor(IEntryPoint anEntryPoint) SemiModularAccountBase(anEntryPoint) {}

Expand Down
1 change: 0 additions & 1 deletion src/helpers/ExecutionInstallDelegate.sol
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,6 @@ contract ExecutionInstallDelegate {
}

function _removeExecHooks(LinkedListSet storage hooks, HookConfig hookConfig) internal {
// Todo: use predecessor
hooks.tryRemove(toSetValue(hookConfig));
}
}
1 change: 0 additions & 1 deletion test/account/ModularAccount.t.sol
Original file line number Diff line number Diff line change
Expand Up @@ -396,7 +396,6 @@ contract ModularAccountTest is AccountTestBase {
vm.stopPrank();
}

// TODO: Consider if this test belongs here or in the tests specific to the SingleSignerValidationModule
function test_transferOwnership() public withSMATest {
if (_isSMATest) {
// Note: replaced "owner1" with address(0), this doesn't actually affect the account, but allows the
Expand Down

0 comments on commit 6106d8d

Please sign in to comment.