-
Notifications
You must be signed in to change notification settings - Fork 2.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
[stdlib] Add split overloads #4015
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: martinvuyk <martin.vuyklop@gmail.com>
d5b9aa1
to
6050f6f
Compare
This looks fantastic and is much easier to keep all the context in my head, making review snappy. Thank you so much for doing that Martin 😄 Other than a question about method placement, this looks ready to go. |
!sync |
Hmm, it seems this is running into Mojo compiler assertion failures in CI internally. I'm able to reproduce a crash using
Are you able to call these new I think this is running into the same parameter inference problem I ran into when I recently did some work on fn split[
sep_mut: Bool,
sep_origin: Origin[sep_mut], //,
](
self,
sep: StringSlice[sep_origin],
maxsplit: Int = -1,
) raises -> List[
String
]: I notice that you still change Originally I thought this PR was writing out each of these overloads as a way you found to workaround that crash, but it appears that may not have been the goal? My best guess is that this issue occurs when something goes wrong inferring origin parameters when |
Signed-off-by: martinvuyk <martin.vuyklop@gmail.com>
@ConnorGray I can't repro the crash
AFAIK the
I didn't experience any crash 🤷♂️ . The Could you test it with reverting back to parametrizing the origin? |
Add all split overloads with examples. Part of #3528
cc: @ConnorGray