-
Notifications
You must be signed in to change notification settings - Fork 90
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 CCArray.of_iter #472
base: main
Are you sure you want to change the base?
add CCArray.of_iter #472
Conversation
illusory0x0
commented
Jan 29, 2025
- CCArray.of_iter missing in containers v3.15 #471
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks useful, do you also want to add the updated benchmarks?
src/core/CCArray.mli
Outdated
val of_iter : 'a iter -> 'a t | ||
(** [of_iter iter] builds a array from a given [iter]. | ||
In the result, elements appear in the same order as they did in the source [iter]. | ||
@since 3.15 *) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I normally use @since NEXT_RELEASE
:)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thanks
should we add more benchmark? when iter_len very small, use list as buffer is faster than other implementation. |
lists might be faster for small sizes, but what about large sizes? does it get worse? |
it would get worse. look this benchmark for more details |