-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
Rollup of 8 pull requests #47435
Closed
Closed
Rollup of 8 pull requests #47435
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
These guarantee that always the requested slice size will be returned and any leftoever elements at the end will be ignored. It allows llvm to get rid of bounds checks in the code using the iterator. This is inspired by the same iterators provided by ndarray. See rust-lang#47115
- Simplify nth() by making use of the fact that the slice is evenly divisible by the chunk size, and calling next() instead of duplicating it - Call next_back() in last(), they are equivalent - Implement ExactSizeIterator::is_empty()
…ter by the compiler And also link from the normal chunks iterator to the exact_chunks one.
…t test This way more useful information is printed if the test ever fails.
…_mut tests Easy enough to do and ensures that the whole chunk is as expected instead of just the element that was looked at before.
These are basically modified copies of the chunks/chunks_mut tests.
When a ui-fulldeps comparison fails it suggests running update-references.sh: ``` src/test/ui-fulldeps/update-references.sh 'rust/build/x86_64-apple-darwin/test/ui-fulldeps' 'resolve-error.rs' ``` This does not work as update-references.sh isn't executable. The other update-references.sh in the ui directory is already executable so this looks like an oversight.
Better Debug impl for io::Error. This PR includes the below changes: 1. The former impl wrapped the entire thing in `Error { repr: ... }` which was unhelpful; this has been removed. 2. The `Os` variant of `io::Error` included the code and message, but not the kind; this has been fixed. 3. The `Custom` variant of `io::Error` included a `Custom(Custom { ... })`, which is now just `Custom { ... }`. Example of previous impl: ```rust Error { repr: Custom( Custom { kind: InvalidData, error: Error { repr: Os { code: 2, message: "no such file or directory" } } } ) } ``` Example of new impl: ```rust Custom { kind: InvalidData, error: Os { code: 2, kind: NotFound, message: "no such file or directory" } } ```
Add slice::ExactChunks and ::ExactChunksMut iterators These guarantee that always the requested slice size will be returned and any leftoever elements at the end will be ignored. It allows llvm to get rid of bounds checks in the code using the iterator. This is inspired by the same iterators provided by ndarray. Fixes rust-lang#47115 I'll add unit tests for all this if the general idea and behaviour makes sense for everybody. Also see rust-lang#47115 (comment) for an example what this improves.
doc: show that `f32::log` and `f64::log` are not correctly rounded Fixes rust-lang#47273. One thing I'm not sure about is whether the "calculated as `self.ln() / base.ln()`" bit is being too specific, maybe we do not want to make this such a strong commitment. I think it's fine, but we should not make commitments in the API documentation by accident. In case that is removed, the added sentence "`self.log2()` can ... base 10." still makes it amply clear that the `log` methods can be more inaccurate than other methods. If the above clause is removed, this second sentence can be moved to the first paragraph, kind of like the accuracy comment for the [`mul_add`](https://doc.rust-lang.org/std/primitive.f32.html#method.mul_add) method.
fix off-by-one error Fixes rust-lang#47325.
…=QuietMisdreavus Switch to pulldown as default markdown renderer r? @QuietMisdreavus
… r=estebank Add error code for unstable feature errors Fixes rust-lang#47397.
Move "no asm" check into AST validation
…nces-exec, r=petrochenkov Make ui-fulldeps/update-references executable When a ui-fulldeps comparison fails it suggests running update-references.sh: ``` src/test/ui-fulldeps/update-references.sh 'rust/build/x86_64-apple-darwin/test/ui-fulldeps' 'resolve-error.rs' ``` This does not work as update-references.sh isn't executable. The other update-references.sh in the ui directory is already executable so this looks like an oversight.
(rust_highfive has picked a reviewer for you, use r? to override) |
@bors: r+ p=10 |
📌 Commit 4ad6ccf has been approved by |
⌛ Testing commit 4ad6ccf with merge 9e05654ce35dcf836e99e343735c993d4160e3d4... |
💔 Test failed - status-travis |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
f32::log
andf64::log
are not correctly rounded #47277, fix off-by-one error #47330, Switch to pulldown as default markdown renderer #47398, Add error code for unstable feature errors #47413, Move "no asm" check into AST validation #47417, Make ui-fulldeps/update-references executable #47432