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

Port NonZero optimization to stable Rust #33

Merged
merged 7 commits into from
Jun 29, 2017
Merged

Port NonZero optimization to stable Rust #33

merged 7 commits into from
Jun 29, 2017

Conversation

SimonSapin
Copy link
Member

@SimonSapin SimonSapin commented Jun 29, 2017

… and various drive-by fixes.


This change is Reviewable

src/util.rs Outdated
impl NonZeroUsize {
#[inline]
pub unsafe fn new(value: usize) -> Self {
NonZeroUsize(&*(value as *const u8))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

debug_assert! it's nonzero?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

core::nonzero::NonZero doesn’t, but sure. Done.

@nox
Copy link
Contributor

nox commented Jun 29, 2017

@bors-servo r+

@bors-servo
Copy link
Contributor

📌 Commit 8d80121 has been approved by nox

@bors-servo
Copy link
Contributor

⌛ Testing commit 8d80121 with merge f9e5c61...

bors-servo pushed a commit that referenced this pull request Jun 29, 2017
Port NonZero optimization to stable Rust

… and various drive-by fixes.

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/tendril/33)
<!-- Reviewable:end -->
@bors-servo
Copy link
Contributor

☀️ Test successful - status-travis
Approved by: nox
Pushing f9e5c61 to master...

@bors-servo bors-servo merged commit 8d80121 into master Jun 29, 2017
@SimonSapin SimonSapin deleted the branch June 29, 2017 19:11
bors-servo pushed a commit to servo/html5ever that referenced this pull request Jun 30, 2017
"unstable" Cargo features are now no-ops, to be removed.

servo/tendril#33

<!-- Reviewable:start -->
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/html5ever/284)
<!-- Reviewable:end -->
bors-servo pushed a commit to servo/html5ever that referenced this pull request Jul 1, 2017
"unstable" Cargo features are now no-ops, to be removed.

servo/tendril#33

<!-- Reviewable:start -->
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/html5ever/284)
<!-- Reviewable:end -->
bors-servo pushed a commit to servo/html5ever that referenced this pull request Jul 1, 2017
"unstable" Cargo features are now no-ops, to be removed.

servo/tendril#33

<!-- Reviewable:start -->
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/html5ever/284)
<!-- Reviewable:end -->
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants