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

refactor: pool/tick_math.gno #161

Merged
merged 3 commits into from
Feb 15, 2024
Merged

refactor: pool/tick_math.gno #161

merged 3 commits into from
Feb 15, 2024

Conversation

notJoon
Copy link
Member

@notJoon notJoon commented Feb 14, 2024

Description

  1. Extract tick ratio values into map (tickRatioMap)
  2. Extracted the individual logic of the TickMathGetTickAtSqrtRatio function into functions.

@notJoon notJoon marked this pull request as ready for review February 14, 2024 07:25
Copy link
Member

@r3v4s r3v4s left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

logic & tc looks good, just couldn't find where number in commnets came from.

@mconcat if pr is suitable for your uint256 approve it

@notJoon
Copy link
Member Author

notJoon commented Feb 14, 2024

couldn't find where number in commnets came from.

@r3v4s I forgot the source, please see the comments at that link

@r3v4s
Copy link
Member

r3v4s commented Feb 14, 2024

couldn't find where number in commnets came from.

@r3v4s I forgot the source, please see the comments at that link

hm... accuracy is 2^14 for some reason?? interesting...

pool/_TEST_tick_math_test.gno Show resolved Hide resolved
pool/tick_math.gno Show resolved Hide resolved
pool/tick_math.gno Show resolved Hide resolved
@r3v4s r3v4s self-requested a review February 15, 2024 01:33
@r3v4s r3v4s merged commit 989905a into gnoswap-labs:main Feb 15, 2024
@r3v4s
Copy link
Member

r3v4s commented Feb 15, 2024

be aware of this pr in future, importing r in p will be forbidden
gnolang/gno#1393

@notJoon notJoon deleted the pool-tick-math branch February 15, 2024 05:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants