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: Optimize quoter codes #53

Merged
merged 1 commit into from
Jul 3, 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
7 changes: 4 additions & 3 deletions src/pool-bin/lens/BinQuoter.sol
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ contract BinQuoter is Quoter, IBinQuoter {

/// @inheritdoc IBinQuoter
function quoteExactInputSingle(QuoteExactSingleParams memory params)
public
external
override
returns (int128[] memory deltaAmounts, uint24 activeIdAfter)
{
Expand All @@ -39,6 +39,7 @@ contract BinQuoter is Quoter, IBinQuoter {
/// @inheritdoc IBinQuoter
function quoteExactInput(QuoteExactParams memory params)
external
override
returns (int128[] memory deltaAmounts, uint24[] memory activeIdAfterList)
{
try vault.lock(abi.encodeWithSelector(this._quoteExactInput.selector, params)) {}
Expand All @@ -49,7 +50,7 @@ contract BinQuoter is Quoter, IBinQuoter {

/// @inheritdoc IBinQuoter
function quoteExactOutputSingle(QuoteExactSingleParams memory params)
public
external
override
returns (int128[] memory deltaAmounts, uint24 activeIdAfter)
{
Expand All @@ -62,7 +63,7 @@ contract BinQuoter is Quoter, IBinQuoter {

/// @inheritdoc IBinQuoter
function quoteExactOutput(QuoteExactParams memory params)
public
external
override
returns (int128[] memory deltaAmounts, uint24[] memory activeIdAfterList)
{
Expand Down
6 changes: 3 additions & 3 deletions src/pool-cl/lens/CLQuoter.sol
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ contract CLQuoter is Quoter, ICLQuoter {

/// @inheritdoc ICLQuoter
function quoteExactInputSingle(QuoteExactSingleParams memory params)
public
external
override
returns (int128[] memory deltaAmounts, uint160 sqrtPriceX96After, uint32 initializedTicksLoaded)
{
Expand Down Expand Up @@ -51,7 +51,7 @@ contract CLQuoter is Quoter, ICLQuoter {

/// @inheritdoc ICLQuoter
function quoteExactOutputSingle(QuoteExactSingleParams memory params)
public
external
override
returns (int128[] memory deltaAmounts, uint160 sqrtPriceX96After, uint32 initializedTicksLoaded)
{
Expand All @@ -64,7 +64,7 @@ contract CLQuoter is Quoter, ICLQuoter {

/// @inheritdoc ICLQuoter
function quoteExactOutput(QuoteExactParams memory params)
public
external
override
returns (
int128[] memory deltaAmounts,
Expand Down
Loading