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

RsETH on Linea #1152

Merged
merged 39 commits into from
Aug 30, 2024
Merged
Show file tree
Hide file tree
Changes from 38 commits
Commits
Show all changes
39 commits
Select commit Hold shift + click to select a range
a480c22
Generated the integration boilerplate
jalextowle Aug 20, 2024
b7af212
Added a conversion library for EzETH on Linea
jalextowle Aug 21, 2024
8770a62
Implemented the `EzETHLineaBase` contract
jalextowle Aug 21, 2024
c61237c
Updated the constructors and deployers
jalextowle Aug 21, 2024
75a2ed0
Wired up the ezETH Linea deployer coordinator
jalextowle Aug 21, 2024
56250c9
Made progress on the tests
jalextowle Aug 23, 2024
19113cb
Finished the integration test
jalextowle Aug 23, 2024
8e52ca7
Added deployment tools for Linea EzETH
jalextowle Aug 23, 2024
56356c4
Merge remote-tracking branch 'origin/main' into jalextowle/integratio…
jalextowle Aug 23, 2024
7d1cb4b
Addressed the remaining FIXME comments
jalextowle Aug 23, 2024
231fc6c
Updated CI
jalextowle Aug 25, 2024
4987b81
Addressed review feedback from @jrhea and @mcclurejt
jalextowle Aug 26, 2024
ee5c35a
Ran prettier
jalextowle Aug 26, 2024
3deabfd
Updated the spell check
jalextowle Aug 26, 2024
0a7a9e2
Pinned the foundry action to a release from a few days ago
jalextowle Aug 26, 2024
2aee31a
Generated the boilerplate for RsETHHyperdrive on Linea
jalextowle Aug 26, 2024
b0367f7
Merge remote-tracking branch 'origin/main' into jalextowle/integratio…
jalextowle Aug 27, 2024
6994293
Implemented the RsETHLinea base and conversion contract
jalextowle Aug 27, 2024
b1b9196
Wired up the boilerplate contracts
jalextowle Aug 27, 2024
e327f0d
Improved the instance test suite
jalextowle Aug 28, 2024
82d8c2c
Refactored the Chainlink instance tests
jalextowle Aug 28, 2024
26c904d
Refactored the etherfi tests
jalextowle Aug 28, 2024
bb84e85
Refactored the SUSDe tests
jalextowle Aug 28, 2024
e71d90d
Refactored the sxDAI test
jalextowle Aug 28, 2024
b8a4c98
Refactored some more tests
jalextowle Aug 29, 2024
a9a6007
Refactored the instance tests for `RETH` and `STETH`
jalextowle Aug 29, 2024
fbb02b7
Updated the feeless Morpho instance tests
jalextowle Aug 29, 2024
f140bdf
Refactored the Morpho test with fees
jalextowle Aug 29, 2024
22f1986
Merge remote-tracking branch 'origin/main' into jalextowle/refactor/i…
jalextowle Aug 29, 2024
d66fe2a
Updated the benchmark script to avoid instance tests
jalextowle Aug 29, 2024
ee6c5f3
Merge remote-tracking branch 'origin/jalextowle/refactor/improve-inst…
jalextowle Aug 29, 2024
db56682
Added tests for RsETH
jalextowle Aug 29, 2024
29a44c9
Updated RsETHLineaHyperdrive so that it supports base when the fees a…
jalextowle Aug 29, 2024
b5941d9
Added a deploy script for RsETH
jalextowle Aug 29, 2024
673ac07
Merge remote-tracking branch 'origin/main' into jalextowle/integratio…
jalextowle Aug 29, 2024
0dc2626
Merge branch 'main' into jalextowle/integration/linea-rseth
jalextowle Aug 30, 2024
724cb9b
Updated the prettier ignore file
jalextowle Aug 30, 2024
1e72dcb
Merge remote-tracking branch 'origin/jalextowle/integration/linea-rse…
jalextowle Aug 30, 2024
dee18e6
Addressed review feedback from @mcclurejt
jalextowle Aug 30, 2024
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
1 change: 1 addition & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
*.js
*.md
*.yaml
*.yml
lib/
!tasks/deploy/lib/
target/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
pragma solidity 0.8.22;

import { IHyperdrive } from "../../interfaces/IHyperdrive.sol";
import { IHyperdriveAdminController } from "../../interfaces/IHyperdriveAdminController.sol";
import { IHyperdriveCoreDeployer } from "../../interfaces/IHyperdriveCoreDeployer.sol";
import { {{ name.capitalized }}Hyperdrive } from "../../instances/{{ name.lowercase }}/{{ name.capitalized }}Hyperdrive.sol";

Expand All @@ -15,6 +16,8 @@ contract {{ name.capitalized }}HyperdriveCoreDeployer is IHyperdriveCoreDeployer
/// @notice Deploys a Hyperdrive instance with the given parameters.
/// @param __name The name of the Hyperdrive pool.
/// @param _config The configuration of the Hyperdrive pool.
/// @param _adminController The admin controller that will specify the
/// admin parameters for this instance.
/// @param _target0 The target0 address.
/// @param _target1 The target1 address.
/// @param _target2 The target2 address.
Expand All @@ -25,6 +28,7 @@ contract {{ name.capitalized }}HyperdriveCoreDeployer is IHyperdriveCoreDeployer
function deployHyperdrive(
string memory __name,
IHyperdrive.PoolConfig memory _config,
IHyperdriveAdminController _adminController,
bytes memory, // unused _extraData,
address _target0,
address _target1,
Expand All @@ -42,6 +46,7 @@ contract {{ name.capitalized }}HyperdriveCoreDeployer is IHyperdriveCoreDeployer
}(
__name,
_config,
_adminController,
_target0,
_target1,
_target2,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ pragma solidity 0.8.22;

import { ERC20 } from "openzeppelin/token/ERC20/ERC20.sol";
import { SafeERC20 } from "openzeppelin/token/ERC20/utils/SafeERC20.sol";
import { {{ name.capitalized }}Conversions } from "../../instances/{{ name.lowercase }}/{{ name.capitalized }}Conversions.sol";
import { I{{ name.capitalized }} } from "../../interfaces/I{{ name.capitalized }}.sol";
import { IHyperdrive } from "../../interfaces/IHyperdrive.sol";
import { I{{ name.capitalized }}Hyperdrive } from "../../interfaces/I{{ name.capitalized }}Hyperdrive.sol";
Expand Down Expand Up @@ -141,7 +142,7 @@ contract {{ name.capitalized }}HyperdriveDeployerCoordinator is HyperdriveDeploy
function convertToBase(
uint256 _shareAmount
) public view returns (uint256) {
// FIXME
return {{ name.capitalized }}Conversions.convertToBase(_shareAmount);
}

/// @notice Convert an amount of base to an amount of vault shares.
Expand All @@ -150,7 +151,7 @@ contract {{ name.capitalized }}HyperdriveDeployerCoordinator is HyperdriveDeploy
function convertToShares(
uint256 _baseAmount
) public view returns (uint256) {
// FIXME
return {{ name.capitalized }}Conversions.convertToShares(_baseAmount);
}

{% if contract.payable %}
Expand All @@ -167,23 +168,27 @@ contract {{ name.capitalized }}HyperdriveDeployerCoordinator is HyperdriveDeploy
}
{% endif %}

// FIXME: Update the extra data comment if the extra data isn't empty.
jalextowle marked this conversation as resolved.
Show resolved Hide resolved
//
/// @notice Checks the pool configuration to ensure that it is valid.
/// @param _deployConfig The deploy configuration of the Hyperdrive pool.
/// @param _extraData The empty extra data.
function _checkPoolConfig(
IHyperdrive.PoolDeployConfig memory _deployConfig
IHyperdrive.PoolDeployConfig memory _deployConfig,
bytes memory _extraData
) internal view override {
// Perform the default checks.
super._checkPoolConfig(_deployConfig);
super._checkPoolConfig(_deployConfig, _extraData);

// ****************************************************************
// FIXME: Implement this for new instances.
jalextowle marked this conversation as resolved.
Show resolved Hide resolved
// Ensure that the vault shares token address is properly configured.
if (address(_deployConfig.vaultSharesToken) != address(VAULT_SHARES_TOKEN) {
if (address(_deployConfig.vaultSharesToken) != address(0)) {
revert IHyperdriveDeployerCoordinator.InvalidVaultSharesToken();
}

// Ensure that the base token address is properly configured.
if (address(_deployConfig.baseToken) == address(0)) {
if (address(_deployConfig.baseToken) != address(0)) {
revert IHyperdriveDeployerCoordinator.InvalidBaseToken();
}
// *****************************************************************
Expand Down
6 changes: 5 additions & 1 deletion codegen/templates/deployers/Target0Deployer.sol.jinja
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ pragma solidity 0.8.22;
import { {{ name.capitalized }}Target0 } from "../../instances/{{ name.lowercase }}/{{ name.capitalized }}Target0.sol";
import { I{{ name.capitalized }} } from "../../interfaces/I{{ name.capitalized }}.sol";
import { IHyperdrive } from "../../interfaces/IHyperdrive.sol";
import { IHyperdriveAdminController } from "../../interfaces/IHyperdriveAdminController.sol";
import { IHyperdriveTargetDeployer } from "../../interfaces/IHyperdriveTargetDeployer.sol";

/// @author DELV
Expand All @@ -15,10 +16,13 @@ import { IHyperdriveTargetDeployer } from "../../interfaces/IHyperdriveTargetDep
contract {{ name.capitalized }}Target0Deployer is IHyperdriveTargetDeployer {
/// @notice Deploys a target0 instance with the given parameters.
/// @param _config The configuration of the Hyperdrive pool.
/// @param _adminController The admin controller that will specify the
/// admin parameters for this instance.
/// @param _salt The create2 salt used in the deployment.
/// @return The address of the newly deployed {{ name.capitalized }}Target0 instance.
function deployTarget(
IHyperdrive.PoolConfig memory _config,
IHyperdriveAdminController _adminController,
bytes memory, // unused _extraData
bytes32 _salt
) external returns (address) {
Expand All @@ -28,7 +32,7 @@ contract {{ name.capitalized }}Target0Deployer is IHyperdriveTargetDeployer {
// front-running of deployments.
new {{ name.capitalized }}Target0{
salt: keccak256(abi.encode(msg.sender, _salt))
}(_config)
}(_config, _adminController)
);
}
}
6 changes: 5 additions & 1 deletion codegen/templates/deployers/Target1Deployer.sol.jinja
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ pragma solidity 0.8.22;
import { {{ name.capitalized }}Target1 } from "../../instances/{{ name.lowercase }}/{{ name.capitalized }}Target1.sol";
import { I{{ name.capitalized }} } from "../../interfaces/I{{ name.capitalized }}.sol";
import { IHyperdrive } from "../../interfaces/IHyperdrive.sol";
import { IHyperdriveAdminController } from "../../interfaces/IHyperdriveAdminController.sol";
import { IHyperdriveTargetDeployer } from "../../interfaces/IHyperdriveTargetDeployer.sol";

/// @author DELV
Expand All @@ -15,10 +16,13 @@ import { IHyperdriveTargetDeployer } from "../../interfaces/IHyperdriveTargetDep
contract {{ name.capitalized }}Target1Deployer is IHyperdriveTargetDeployer {
/// @notice Deploys a target1 instance with the given parameters.
/// @param _config The configuration of the Hyperdrive pool.
/// @param _adminController The admin controller that will specify the
/// admin parameters for this instance.
/// @param _salt The create2 salt used in the deployment.
/// @return The address of the newly deployed {{ name.capitalized }}Target1 instance.
function deployTarget(
IHyperdrive.PoolConfig memory _config,
IHyperdriveAdminController _adminController,
bytes memory, // unused _extraData
bytes32 _salt
) external returns (address) {
Expand All @@ -28,7 +32,7 @@ contract {{ name.capitalized }}Target1Deployer is IHyperdriveTargetDeployer {
// front-running of deployments.
new {{ name.capitalized }}Target1{
salt: keccak256(abi.encode(msg.sender, _salt))
}(_config)
}(_config, _adminController)
);
}
}
6 changes: 5 additions & 1 deletion codegen/templates/deployers/Target2Deployer.sol.jinja
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ pragma solidity 0.8.22;
import { {{ name.capitalized }}Target2 } from "../../instances/{{ name.lowercase }}/{{ name.capitalized }}Target2.sol";
import { I{{ name.capitalized }} } from "../../interfaces/I{{ name.capitalized }}.sol";
import { IHyperdrive } from "../../interfaces/IHyperdrive.sol";
import { IHyperdriveAdminController } from "../../interfaces/IHyperdriveAdminController.sol";
import { IHyperdriveTargetDeployer } from "../../interfaces/IHyperdriveTargetDeployer.sol";

/// @author DELV
Expand All @@ -15,10 +16,13 @@ import { IHyperdriveTargetDeployer } from "../../interfaces/IHyperdriveTargetDep
contract {{ name.capitalized }}Target2Deployer is IHyperdriveTargetDeployer {
/// @notice Deploys a target2 instance with the given parameters.
/// @param _config The configuration of the Hyperdrive pool.
/// @param _adminController The admin controller that will specify the
/// admin parameters for this instance.
/// @param _salt The create2 salt used in the deployment.
/// @return The address of the newly deployed {{ name.capitalized }}Target2 instance.
function deployTarget(
IHyperdrive.PoolConfig memory _config,
IHyperdriveAdminController _adminController,
bytes memory, // unused _extraData
bytes32 _salt
) external returns (address) {
Expand All @@ -28,7 +32,7 @@ contract {{ name.capitalized }}Target2Deployer is IHyperdriveTargetDeployer {
// front-running of deployments.
new {{ name.capitalized }}Target2{
salt: keccak256(abi.encode(msg.sender, _salt))
}(_config)
}(_config, _adminController)
);
}
}
6 changes: 5 additions & 1 deletion codegen/templates/deployers/Target3Deployer.sol.jinja
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ pragma solidity 0.8.22;
import { {{ name.capitalized }}Target3 } from "../../instances/{{ name.lowercase }}/{{ name.capitalized }}Target3.sol";
import { I{{ name.capitalized }} } from "../../interfaces/I{{ name.capitalized }}.sol";
import { IHyperdrive } from "../../interfaces/IHyperdrive.sol";
import { IHyperdriveAdminController } from "../../interfaces/IHyperdriveAdminController.sol";
import { IHyperdriveTargetDeployer } from "../../interfaces/IHyperdriveTargetDeployer.sol";

/// @author DELV
Expand All @@ -15,10 +16,13 @@ import { IHyperdriveTargetDeployer } from "../../interfaces/IHyperdriveTargetDep
contract {{ name.capitalized }}Target3Deployer is IHyperdriveTargetDeployer {
/// @notice Deploys a target3 instance with the given parameters.
/// @param _config The configuration of the Hyperdrive pool.
/// @param _adminController The admin controller that will specify the
/// admin parameters for this instance.
/// @param _salt The create2 salt used in the deployment.
/// @return The address of the newly deployed {{ name.capitalized }}Target3 instance.
function deployTarget(
IHyperdrive.PoolConfig memory _config,
IHyperdriveAdminController _adminController,
bytes memory, // unused _extraData
bytes32 _salt
) external returns (address) {
Expand All @@ -28,7 +32,7 @@ contract {{ name.capitalized }}Target3Deployer is IHyperdriveTargetDeployer {
// front-running of deployments.
new {{ name.capitalized }}Target3{
salt: keccak256(abi.encode(msg.sender, _salt))
}(_config)
}(_config, _adminController)
);
}
}
6 changes: 5 additions & 1 deletion codegen/templates/deployers/Target4Deployer.sol.jinja
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ pragma solidity 0.8.22;
import { {{ name.capitalized }}Target4 } from "../../instances/{{ name.lowercase }}/{{ name.capitalized }}Target4.sol";
import { I{{ name.capitalized }} } from "../../interfaces/I{{ name.capitalized }}.sol";
import { IHyperdrive } from "../../interfaces/IHyperdrive.sol";
import { IHyperdriveAdminController } from "../../interfaces/IHyperdriveAdminController.sol";
import { IHyperdriveTargetDeployer } from "../../interfaces/IHyperdriveTargetDeployer.sol";

/// @author DELV
Expand All @@ -15,10 +16,13 @@ import { IHyperdriveTargetDeployer } from "../../interfaces/IHyperdriveTargetDep
contract {{ name.capitalized }}Target4Deployer is IHyperdriveTargetDeployer {
/// @notice Deploys a target4 instance with the given parameters.
/// @param _config The configuration of the Hyperdrive pool.
/// @param _adminController The admin controller that will specify the
/// admin parameters for this instance.
/// @param _salt The create2 salt used in the deployment.
/// @return The address of the newly deployed {{ name.capitalized }}Target4 instance.
function deployTarget(
IHyperdrive.PoolConfig memory _config,
IHyperdriveAdminController _adminController,
bytes memory, // unused _extraData
bytes32 _salt
) external returns (address) {
Expand All @@ -28,7 +32,7 @@ contract {{ name.capitalized }}Target4Deployer is IHyperdriveTargetDeployer {
// front-running of deployments.
new {{ name.capitalized }}Target4{
salt: keccak256(abi.encode(msg.sender, _salt))
}(_config)
}(_config, _adminController)
);
}
}
5 changes: 5 additions & 0 deletions codegen/templates/instances/Hyperdrive.sol.jinja
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import { SafeERC20 } from "openzeppelin/token/ERC20/utils/SafeERC20.sol";
import { Hyperdrive } from "../../external/Hyperdrive.sol";
import { IERC20 } from "../../interfaces/IERC20.sol";
import { IHyperdrive } from "../../interfaces/IHyperdrive.sol";
import { IHyperdriveAdminController } from "../../interfaces/IHyperdriveAdminController.sol";
import { {{ name.capitalized }}Base } from "./{{ name.capitalized }}Base.sol";

/// ______ __ _________ _____
Expand Down Expand Up @@ -60,6 +61,8 @@ contract {{ name.capitalized }}Hyperdrive is Hyperdrive, {{ name.capitalized }}B
/// @notice Instantiates Hyperdrive with a {{ name.capitalized }} vault as the yield source.
/// @param __name The pool's name.
/// @param _config The configuration of the Hyperdrive pool.
/// @param __adminController The admin controller that will specify the
/// admin parameters for this instance.
/// @param _target0 The target0 address.
/// @param _target1 The target1 address.
/// @param _target2 The target2 address.
Expand All @@ -68,6 +71,7 @@ contract {{ name.capitalized }}Hyperdrive is Hyperdrive, {{ name.capitalized }}B
constructor(
string memory __name,
IHyperdrive.PoolConfig memory _config,
IHyperdriveAdminController __adminController,
address _target0,
address _target1,
address _target2,
Expand All @@ -77,6 +81,7 @@ contract {{ name.capitalized }}Hyperdrive is Hyperdrive, {{ name.capitalized }}B
Hyperdrive(
__name,
_config,
__adminController,
_target0,
_target1,
_target2,
Expand Down
8 changes: 6 additions & 2 deletions codegen/templates/instances/Target0.sol.jinja
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ pragma solidity 0.8.22;

import { HyperdriveTarget0 } from "../../external/HyperdriveTarget0.sol";
import { IHyperdrive } from "../../interfaces/IHyperdrive.sol";
import { IHyperdriveAdminController } from "../../interfaces/IHyperdriveAdminController.sol";
import { {{ name.uppercase }}_HYPERDRIVE_KIND } from "../../libraries/Constants.sol";
import { {{ name.capitalized }}Base } from "./{{ name.capitalized }}Base.sol";

Expand All @@ -17,9 +18,12 @@ import { {{ name.capitalized }}Base } from "./{{ name.capitalized }}Base.sol";
contract {{ name.capitalized }}Target0 is HyperdriveTarget0, {{ name.capitalized }}Base {
/// @notice Initializes the target0 contract.
/// @param _config The configuration of the Hyperdrive pool.
/// @param __adminController The admin controller that will specify the
/// admin parameters for this instance.
constructor(
IHyperdrive.PoolConfig memory _config
) HyperdriveTarget0(_config) {}
IHyperdrive.PoolConfig memory _config,
IHyperdriveAdminController __adminController
) HyperdriveTarget0(_config, __adminController) {}

/// @notice Returns the instance's kind.
/// @return The instance's kind.
Expand Down
8 changes: 6 additions & 2 deletions codegen/templates/instances/Target1.sol.jinja
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ pragma solidity 0.8.22;

import { HyperdriveTarget1 } from "../../external/HyperdriveTarget1.sol";
import { IHyperdrive } from "../../interfaces/IHyperdrive.sol";
import { IHyperdriveAdminController } from "../../interfaces/IHyperdriveAdminController.sol";
import { {{ name.capitalized }}Base } from "./{{ name.capitalized }}Base.sol";

/// @author DELV
Expand All @@ -16,7 +17,10 @@ import { {{ name.capitalized }}Base } from "./{{ name.capitalized }}Base.sol";
contract {{ name.capitalized }}Target1 is HyperdriveTarget1, {{ name.capitalized }}Base {
/// @notice Initializes the target1 contract.
/// @param _config The configuration of the Hyperdrive pool.
/// @param __adminController The admin controller that will specify the
/// admin parameters for this instance.
constructor(
IHyperdrive.PoolConfig memory _config
) HyperdriveTarget1(_config) {}
IHyperdrive.PoolConfig memory _config,
IHyperdriveAdminController __adminController
) HyperdriveTarget1(_config, __adminController) {}
}
8 changes: 6 additions & 2 deletions codegen/templates/instances/Target2.sol.jinja
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ pragma solidity 0.8.22;

import { HyperdriveTarget2 } from "../../external/HyperdriveTarget2.sol";
import { IHyperdrive } from "../../interfaces/IHyperdrive.sol";
import { IHyperdriveAdminController } from "../../interfaces/IHyperdriveAdminController.sol";
import { {{ name.capitalized }}Base } from "./{{ name.capitalized }}Base.sol";

/// @author DELV
Expand All @@ -16,7 +17,10 @@ import { {{ name.capitalized }}Base } from "./{{ name.capitalized }}Base.sol";
contract {{ name.capitalized }}Target2 is HyperdriveTarget2, {{ name.capitalized }}Base {
/// @notice Initializes the target2 contract.
/// @param _config The configuration of the Hyperdrive pool.
/// @param __adminController The admin controller that will specify the
/// admin parameters for this instance.
constructor(
IHyperdrive.PoolConfig memory _config
) HyperdriveTarget2(_config) {}
IHyperdrive.PoolConfig memory _config,
IHyperdriveAdminController __adminController
) HyperdriveTarget2(_config, __adminController) {}
}
8 changes: 6 additions & 2 deletions codegen/templates/instances/Target3.sol.jinja
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ pragma solidity 0.8.22;

import { HyperdriveTarget3 } from "../../external/HyperdriveTarget3.sol";
import { IHyperdrive } from "../../interfaces/IHyperdrive.sol";
import { IHyperdriveAdminController } from "../../interfaces/IHyperdriveAdminController.sol";
import { {{ name.capitalized }}Base } from "./{{ name.capitalized }}Base.sol";

/// @author DELV
Expand All @@ -16,7 +17,10 @@ import { {{ name.capitalized }}Base } from "./{{ name.capitalized }}Base.sol";
contract {{ name.capitalized }}Target3 is HyperdriveTarget3, {{ name.capitalized }}Base {
/// @notice Initializes the target3 contract.
/// @param _config The configuration of the Hyperdrive pool.
/// @param __adminController The admin controller that will specify the
/// admin parameters for this instance.
constructor(
IHyperdrive.PoolConfig memory _config
) HyperdriveTarget3(_config) {}
IHyperdrive.PoolConfig memory _config,
IHyperdriveAdminController __adminController
) HyperdriveTarget3(_config, __adminController) {}
}
8 changes: 6 additions & 2 deletions codegen/templates/instances/Target4.sol.jinja
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ pragma solidity 0.8.22;

import { HyperdriveTarget4 } from "../../external/HyperdriveTarget4.sol";
import { IHyperdrive } from "../../interfaces/IHyperdrive.sol";
import { IHyperdriveAdminController } from "../../interfaces/IHyperdriveAdminController.sol";
import { {{ name.capitalized }}Base } from "./{{ name.capitalized }}Base.sol";

/// @author DELV
Expand All @@ -16,7 +17,10 @@ import { {{ name.capitalized }}Base } from "./{{ name.capitalized }}Base.sol";
contract {{ name.capitalized }}Target4 is HyperdriveTarget4, {{ name.capitalized }}Base {
/// @notice Initializes the target4 contract.
/// @param _config The configuration of the Hyperdrive pool.
/// @param __adminController The admin controller that will specify the
/// admin parameters for this instance.
constructor(
IHyperdrive.PoolConfig memory _config
) HyperdriveTarget4(_config) {}
IHyperdrive.PoolConfig memory _config,
IHyperdriveAdminController __adminController
) HyperdriveTarget4(_config, __adminController) {}
}
Loading
Loading