-
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
Rollup of 10 pull requests #92970
Rollup of 10 pull requests #92970
Conversation
Useful for thin wrapper attributes that are best passed as value instead of reference.
…ng projection holds
This hack was added in 6ab1f05. I don't know what change allowed removing the hack, but that commit added a test (which I presume covered the hack's behavior), and all tests are passing with this change. So, I think it should be good.
Inherent associated types *are* supported, just unstable.
This currently calls `std` a "crate" in one part of the message and a "module" in another part. The next commits fix this so it says "crate" in both places.
This allows simplifying a lot of code. It also fixes a subtle bug, exemplified by the test output changes.
Now that `res` is used directly, it seems the conditional is unnecessary.
I'm still not sure why this hack works so seemingly well.
These closures were quite complex and part of a quite complex function. The fact that they are closures makes mistakes likely when refactoring. For example, earlier, I meant to use `resolved`, an argument of the closure, but I instead typed `res`, which captured a local variable and caused a subtle bug that led to a confusing test failure. Extracting them as functions makes the code easier to understand and refactor.
includes minor refactorings
Swift has specific syntax that desugars to `Option<T>` similar to our `?` operator, which means that people might try to use it in Rust. Parse it and gracefully recover.
Yield means something else in the context of generators, which are sufficiently close to iterators that it's better to avoid the terminology collision here.
Fix unclosed boxes in pretty printing of TraitAlias This was causing trait aliases to not even render at all in stringified / pretty printed output. ```rust macro_rules! repro { ($item:item) => { stringify!($item) }; } fn main() { println!("{:?}", repro!(pub trait Trait<T> = Sized where T: 'a;)); } ``` Before: `""` After: `"pub trait Trait<T> = Sized where T: 'a;"` The fix is copied from how `head`/`end` for `ItemKind::Use`, `ItemKind::ExternCrate`, and `ItemKind::Mod` are all done in the pretty printer: https://github.com/rust-lang/rust/blob/dd3ac41495e85a9b7b5cb3186379d02ce17e51fe/compiler/rustc_ast_pretty/src/pprust/state.rs#L1178-L1184
ARMv6K Horizon - Enable default libraries Due to the nature of the external gcc linker, default libraries are required, even for `no_std` programs.
…=matthewjasper Add diagnostic items for macros For use in Clippy, it adds diagnostic items to all the stable public macros Clippy has lints that look for almost all of these (currently by name or path), but there are a few that aren't currently part of any lint, I could remove those if it's preferred to add them as needed rather than ahead of time
…arth rustdoc: Yet more intra-doc links cleanup r? `@Manishearth`
feat: rustc_pass_by_value lint attribute Useful for thin wrapper attributes that are best passed as value instead of reference. Fixes rust-lang#76935
Clarify explicitly that BTree{Map,Set} are ordered. One of the main reasons one would want to use a BTree{Map,Set} rather than a Hash{Map,Set} is because they maintain their keys in sorted order; but this was never explicitly stated in the top-level docs (it was only indirectly alluded to there, and stated explicitly in the docs for `iter`, `values`, etc.) This PR states the ordering guarantee more prominently.
Include Projections when elaborating TypeOutlives Fixes rust-lang#92280 In `Elaborator`, we elaborate that `Foo<<Bar as Baz>::Assoc>: 'a` -> `<Bar as Baz>::Assoc: 'a`. This is the same rule that would be applied to any other `Param`. If there are escaping vars, we continue to do nothing. r? `@nikomatsakis`
…avidtwco Parse `Ty?` as `Option<Ty>` and provide structured suggestion Swift has specific syntax that desugars to `Option<T>` similar to our `?` operator, which means that people might try to use it in Rust. Parse it and gracefully recover.
…cs, r=camelid rustdoc: fix intra-link for generic trait impls fixes rust-lang#92662 r? `````@camelid`````
remove unused FIXME rust-lang#56935 seems to be fixed.
@bors r+ rollup=never p=10 |
📌 Commit 2b6b49e has been approved by |
☀️ Test successful - checks-actions |
Finished benchmarking commit (bd3cb52): comparison url. Summary: This change led to moderate relevant regressions 😿 in compiler performance.
If you disagree with this performance assessment, please file an issue in rust-lang/rustc-perf. Next Steps: If you can justify the regressions found in this perf run, please indicate this with @rustbot label: +perf-regression |
Regression here seems small enough and limited to just one benchmark's incr runs that I'm going to mark this as triaged -- it doesn't seem worth further investigation. |
Successful merges:
Ty?
asOption<Ty>
and provide structured suggestion #92746 (ParseTy?
asOption<Ty>
and provide structured suggestion)Failed merges:
r? @ghost
@rustbot modify labels: rollup
Create a similar rollup