-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
allow string split by char with yield #2541
Conversation
Indeed, yielding slices will be much more efficient because no copying is needed. However, I would expect Maybe we can have a |
A nicer alternative could be having a readonly |
added split_slice, |
Yes, something like a |
I didn't notice before that |
@lbguilherme There are two issues:
|
I don't quite follow the public API usecases for |
useful when you reuse parts of string, instead of create new, example: https://github.com/kostya/simple_idn/blob/master/src/simple_idn.cr#L231 (here i implement this method by myself) |
I'd eventually like to have String-like methods for |
sometimes this is needed for speed