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

Add TickList trait and tests #1

Merged
merged 2 commits into from
Jan 1, 2024
Merged

Add TickList trait and tests #1

merged 2 commits into from
Jan 1, 2024

Conversation

shuhuiluo
Copy link
Owner

No description provided.

A `TickList` trait has been implemented to handle tick-related tasks such as binary search, position checking, and list validation on array slices. A `Tick` structure and a `TickTrait` were created to manage ticks more efficiently. Relevant test cases were also added. This update is marked by a version change to 0.4.0.
Functions in the `sqrt_price_math.rs` and `nearest_usable_tick.rs` files, as well as the `constants.rs` file, were changed from regular to `const` functions. This provides the capacity to have these functions evaluated at compile time wherever their usage throughout the codebase makes it possible for constant evaluation. Also, updated the tick comparison in `nearest_usable_tick.rs` which ensures more readability.
@shuhuiluo shuhuiluo self-assigned this Jan 1, 2024
@shuhuiluo shuhuiluo merged commit 200ec9f into master Jan 1, 2024
2 checks passed
@shuhuiluo shuhuiluo deleted the tick_list branch January 1, 2024 09:06
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.

1 participant