-
Notifications
You must be signed in to change notification settings - Fork 12.7k
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 10 pull requests #89047
Rollup of 10 pull requests #89047
Conversation
…p of files This is a straightforward wrapper that uses the existing helpers for C string handling and errno handling. Having this available is convenient for UNIX utility programs written in Rust, and avoids having to call unsafe functions like `libc::chown` directly and handle errors manually, in a program that may otherwise be entirely safe code. In addition, these functions provide a more Rustic interface by accepting appropriate traits and using `None` rather than `-1`.
If #![feature] is used outside the nightly channel for only lib features, the check will be delayed to the stability pass after parsing. This is done so that appropriate help messages can be shown if the #![feature] has been used needlessly
…op, r=estebank Emit clearer diagnostics for parens around `for` loop heads Fixes rust-lang#63113 r? `@estebank`
Point to closure when emitting 'cannot move out' for captured variable Attempts to fix rust-lang#87456. The error message now points to the capturing closure, but I was not able to explain _why_ the closure implements `Fn` or `FnMut` (`TypeckResults::closure_kind_origins` did not contain anything for the closure in question). cc `@Aaron1011`
…ounds, r=estebank Recover invalid assoc type bounds using `==` Fix rust-lang#87493 r? `@estebank`
…k-Simulacrum Improve build command for compiler docs It was rather complicated to document rustc crates. With this, you can directly run: ```console x.py doc compiler x.py doc compiler/rustc_hir_pretty ``` The second commit adds the handling of the `--open` flag. r? `@Mark-Simulacrum`
…asper Do not issue E0071 if a type error has already been reported Fixes rust-lang#88844. A suggested fix is already included in the error message for E0412, so with my changes, E0071 is simply not emitted anymore if the type in question is a "type error". This makes sense, I think, because we cannot confidently state that something is "not a struct" if we couldn't resolve it properly; and it's unnecessary to pollute the output with this additional error message, as it is a direct consequence of the former error. I have also addressed the issue mentioned in rust-lang#88844 (comment) by changing the fixed example in the documentation to more closely match the erroneous code example.
Fix handling of `hir::GenericArg::Infer` in `wrong_number_of_generic_args.rs` Fixes rust-lang#87563. More precisely, I have fixed the "index out of bounds" error, which is what rust-lang#87563 is about. The example given there still ICEs due to running into this `todo!()`, but I'd say that this is a separate issue: https://github.com/rust-lang/rust/blob/c3c0f80d6081092faff801542dd82f0e2420152b/compiler/rustc_typeck/src/astconv/mod.rs#L460-L463
Add chown functions to std::os::unix::fs to change the owner and group of files This is a straightforward wrapper that uses the existing helpers for C string handling and errno handling. Having this available is convenient for UNIX utility programs written in Rust, and avoids having to call unsafe functions like `libc::chown` directly and handle errors manually, in a program that may otherwise be entirely safe code. In addition, these functions provide a more Rustic interface by accepting appropriate traits and using `None` rather than `-1`.
Allow `panic!("{}", computed_str)` in const fn. Special-case `panic!("{}", arg)` and translate it to `panic_display(&arg)`. `panic_display` will behave like `panic_any` in cosnt eval and behave like `panic!(format_args!("{}", arg))` in runtime. This should bring Rust 2015 and 2021 to feature parity in terms of `const_panic`; and hopefully would unblock the stabilisation of rust-lang#51999. `@rustbot` modify labels: +T-compiler +T-libs +A-const-eval +A-const-fn r? `@oli-obk`
Add rustdoc version into the help popup After a discussion with a rustdoc user about a specific behaviour, we realized we were not talking about the same version. To add on top of it, it was actually not that simple to find out the version since it was hosted documentation. So to simplify things, I added the version into the help popup: ![Screenshot from 2021-09-16 10-45-52](https://user-images.githubusercontent.com/3050060/133581128-b93b460a-e1cb-4a31-9f2f-97c7a916cfcc.png) Does the version format looks or would you prefer that I add more information? We can also add the commit hash, commit date, host and release. cc `@rust-lang/rustdoc` r? `@jyn514`
Suggest removing `#![feature]` for library features that have been stabilized Issue: rust-lang#88802 Delayed the check if #![feature] has been used to enable lib features in a non-nightly build to occur after TyCtxt has been constructed.
@bors: r+ p=10 rollup=never |
📌 Commit 101a88f has been approved by |
☀️ Test successful - checks-actions |
Weekly performance triage. This PR was identified as the source of a +1.9% regression in instruction counts for webrender-wrench-check. I don't have any intuition about that benchmark or why this rollup would significantly affect its compilation time, though. |
Successful merges:
for
loop heads #86422 (Emit clearer diagnostics for parens aroundfor
loop heads)==
#87566 (Recover invalid assoc type bounds using==
)hir::GenericArg::Infer
inwrong_number_of_generic_args.rs
#88949 (Fix handling ofhir::GenericArg::Infer
inwrong_number_of_generic_args.rs
)panic!("{}", computed_str)
in const fn. #88954 (Allowpanic!("{}", computed_str)
in const fn.)#![feature]
for library features that have been stabilized #89012 (Suggest removing#![feature]
for library features that have been stabilized)Failed merges:
r? @ghost
@rustbot modify labels: rollup
Create a similar rollup