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

Rename repeatn #1237

Closed
SyxtonPrime opened this issue Apr 3, 2025 · 1 comment · Fixed by #1239
Closed

Rename repeatn #1237

SyxtonPrime opened this issue Apr 3, 2025 · 1 comment · Fixed by #1239

Comments

@SyxtonPrime
Copy link

As of rust 1.82.0, The standard library includes the function repeat_n (https://doc.rust-lang.org/std/iter/fn.repeat_n.html) which takes an element and a usize and constructs the iterator which repeats the element n times.

Rayon includes the same function (https://docs.rs/rayon/latest/rayon/iter/fn.repeatn.html) but uses a slightly different name (repeatn instead of repeat_n) .

Clearly not a high priority but it would be nice to fix this so the names match up.

@cuviper
Copy link
Member

cuviper commented Apr 3, 2025

Yeah, I agree that we should match repeat_n, deprecating repeatn.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants