-
Notifications
You must be signed in to change notification settings - Fork 12.9k
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 to as str #17171
Rename to as str #17171
Conversation
This closes rust-lang#14433 [breaking-change]
I just realised that I've definitely missed a bunch of windows and linux specific code. I can stand up a test environment for linux, but will probably need something with a windows environment to help me, it will probably really suck to shotgun patch this with bors. |
cc @aturon, @alexcrichton, @brson |
bdf607f
to
6e06da8
Compare
We were talking about this with reference to the stabilization of Once rust-lang/rfcs#198 is implemented, then we'll likely just use |
Works for me. Edit, thinking about it, having just been through ~1000 instances of peeking at a String's underlying slice in rust/the stdlib it seems like a great deal of it is either not indexing it, or indexing it elsewhere (eg, it either passes the slice into something else, or returns the slice). That said, I'm not against shelving this and dealing with it down the road. |
@alexcrichton Wait, did that just implicitly make slice syntax a 1.0 blocker? We should discuss that and make a decision explicitly... |
Slice notation has since landed, but with rust-lang/rfcs#235 landing soon it should hopefully reduce the need for lots of |
Closes #14433
Testing is difficult (I'm on a laptop without power so builds are concerning) but stage0 builds fine with this patch.
Waiting on a stage1 now. Obviously this breaks the vast majority of code that uses
String