-
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
Introduce RangeInclusive::{new, start, end} methods and make the fields private. #49724
Conversation
r? @Kimundi (rust_highfive has picked a reviewer for you, use r? to override) |
I suspect this can be done without introducing |
d6b7342
to
2415f53
Compare
2415f53
to
8ea4d30
Compare
@petrochenkov That sounds like a huge hack to just avoid adding a new function 😅, and it also ties the lowering to whatever internal representation we will choose in the future. There's also support of adding a constructor function as well. |
8ea4d30
to
b7b82d3
Compare
☔ The latest upstream changes (presumably #48779) made this pull request unmergeable. Please resolve the merge conflicts. |
b7b82d3
to
def13dd
Compare
(Blocked by FCP in #49022) |
One additional thing this stabilizes that might be worth considering: The post-iteration values of The docs say not to rely on it, but right now it goes to |
@scottmcm Added docs to say the values are unspecified. I expect we are going to abandon RFC 1980 since the representation is now a private detail, in favor of performance. There will likely be a boolean field representing whether iteration has been completed. |
@kennytm Yup, that outcome for iteration wouldn't surprise me at all. (It can't be done with today's |
(FCP of #49022 has completed) |
☔ The latest upstream changes (presumably #49757) made this pull request unmergeable. Please resolve the merge conflicts. |
Added new()/start()/end() methods to RangeInclusive. Changed the lowering of `..=` to use RangeInclusive::new().
e3dbebc
to
8379deb
Compare
This comment has been minimized.
This comment has been minimized.
8379deb
to
d52ec99
Compare
This comment has been minimized.
This comment has been minimized.
6967c8d
to
61fc692
Compare
This comment has been minimized.
This comment has been minimized.
61fc692
to
f70b2eb
Compare
@bors r=Kimundi (Approved by #49724 (review)) |
📌 Commit f70b2eb has been approved by |
Introduce RangeInclusive::{new, start, end} methods and make the fields private. cc #49022
☀️ Test successful - status-appveyor, status-travis |
cc #49022