-
Notifications
You must be signed in to change notification settings - Fork 12.6k
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 14 pull requests #122711
Rollup of 14 pull requests #122711
Commits on Mar 6, 2024
-
Configuration menu - View commit details
-
Copy full SHA for c7030e9 - Browse repository at this point
Copy the full SHA c7030e9View commit details
Commits on Mar 8, 2024
-
Configuration menu - View commit details
-
Copy full SHA for c63f3fe - Browse repository at this point
Copy the full SHA c63f3feView commit details
Commits on Mar 12, 2024
-
Gracefully handle AnonConst in diagnostic_hir_wf_check()
when it is the default value of a generic param
Configuration menu - View commit details
-
Copy full SHA for d0e4a3b - Browse repository at this point
Copy the full SHA d0e4a3bView commit details
Commits on Mar 13, 2024
-
Configuration menu - View commit details
-
Copy full SHA for d26c572 - Browse repository at this point
Copy the full SHA d26c572View commit details -
Configuration menu - View commit details
-
Copy full SHA for 0b2fb8d - Browse repository at this point
Copy the full SHA 0b2fb8dView commit details
Commits on Mar 17, 2024
-
Configuration menu - View commit details
-
Copy full SHA for d7b4b01 - Browse repository at this point
Copy the full SHA d7b4b01View commit details -
Configuration menu - View commit details
-
Copy full SHA for 23e1b57 - Browse repository at this point
Copy the full SHA 23e1b57View commit details
Commits on Mar 18, 2024
-
Configuration menu - View commit details
-
Copy full SHA for 33c274f - Browse repository at this point
Copy the full SHA 33c274fView commit details -
Configuration menu - View commit details
-
Copy full SHA for f26e1e8 - Browse repository at this point
Copy the full SHA f26e1e8View commit details -
Configuration menu - View commit details
-
Copy full SHA for 935842b - Browse repository at this point
Copy the full SHA 935842bView commit details -
Configuration menu - View commit details
-
Copy full SHA for efa4269 - Browse repository at this point
Copy the full SHA efa4269View commit details -
Fix ICE:
global_asm!()
Don't Panic When Unable to Evaluate ConstantA bit of an inelegant fix but given that the error is created only after call to `const_eval_poly()` and that the calling function cannot propagate the error anywhere else, the error has to be explicitly handled inside `mono_item.rs`.
Configuration menu - View commit details
-
Copy full SHA for 97cc700 - Browse repository at this point
Copy the full SHA 97cc700View commit details -
Configuration menu - View commit details
-
Copy full SHA for 39f2d25 - Browse repository at this point
Copy the full SHA 39f2d25View commit details -
Configuration menu - View commit details
-
Copy full SHA for 8124b26 - Browse repository at this point
Copy the full SHA 8124b26View commit details -
Configuration menu - View commit details
-
Copy full SHA for e34e344 - Browse repository at this point
Copy the full SHA e34e344View commit details -
Configuration menu - View commit details
-
Copy full SHA for 7c5a99b - Browse repository at this point
Copy the full SHA 7c5a99bView commit details -
Configuration menu - View commit details
-
Copy full SHA for 0b29b71 - Browse repository at this point
Copy the full SHA 0b29b71View commit details -
Fix a typo in the 1.77.0 relnotes
Co-authored-by: Mateusz Mikuła <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for 4739948 - Browse repository at this point
Copy the full SHA 4739948View commit details -
Configuration menu - View commit details
-
Copy full SHA for 0db06bf - Browse repository at this point
Copy the full SHA 0db06bfView commit details -
Deduplicate
associated_body
andbody_id
They match on almost the same patterns, which is fishy. Also turn `associated_body` into a method and do some cleanups nearby the call sites
Configuration menu - View commit details
-
Copy full SHA for 419d205 - Browse repository at this point
Copy the full SHA 419d205View commit details -
Use
hir::Node
helper methods instead of repeat the same impl multip……le times There already were inconsistencies, so this ensures we don't introduce subtle surprising bugs
Configuration menu - View commit details
-
Copy full SHA for 69c4e81 - Browse repository at this point
Copy the full SHA 69c4e81View commit details -
Configuration menu - View commit details
-
Copy full SHA for 9b0cbe3 - Browse repository at this point
Copy the full SHA 9b0cbe3View commit details -
Rollup merge of rust-lang#121258 - fmease:assoc-const-eq-reject-overl…
…y-generic-tys, r=compiler-errors Reject overly generic assoc const binding types Split off from rust-lang#119385 to make rust-lang#119385 easier to review. --- In the *instantiated* type of assoc const bindings 1. reject **early-bound generic params** * Provide a rich error message instead of ICE'ing ([rust-lang#108271](rust-lang#108271)). * This is a temporary and semi-artificial restriction until the arrival of *generic const generics*. * It's quite possible that rustc could already perfectly support this subset of generic const generics if we just removed some checks (some `.no_bound_vars().expect(…)`) but even if that was the case, I'd rather gate it behind a new feature flag. Reporting an error instead of ICE'ing is a good first step towards an eventual feature gate error. 2. reject **escaping late-bound generic params** * They lead to ICEs before & I'm pretty sure that they remain incorrect even in a world with *generic const generics* --- Together with rust-lang#118668 & rust-lang#119385, this supersedes rust-lang#118360. Fixes rust-lang#108271.
Configuration menu - View commit details
-
Copy full SHA for 5fd8878 - Browse repository at this point
Copy the full SHA 5fd8878View commit details -
Rollup merge of rust-lang#122021 - oli-obk:delangitemification, r=com…
…piler-errors Use hir::Node helper methods instead of repeating the same impl multiple times I wanted to do something entirely different and stumbled upon a bunch of cleanups
Configuration menu - View commit details
-
Copy full SHA for d6a2918 - Browse repository at this point
Copy the full SHA d6a2918View commit details -
Rollup merge of rust-lang#122055 - compiler-errors:stabilize-atb, r=o…
…li-obk Stabilize associated type bounds (RFC 2289) This PR stabilizes associated type bounds, which were laid out in [RFC 2289]. This gives us a shorthand to express nested type bounds that would otherwise need to be expressed with nested `impl Trait` or broken into several `where` clauses. ### What are we stabilizing? We're stabilizing the associated item bounds syntax, which allows us to put bounds in associated type position within other bounds, i.e. `T: Trait<Assoc: Bounds...>`. See [RFC 2289] for motivation. In all position, the associated type bound syntax expands into a set of two (or more) bounds, and never anything else (see "How does this differ[...]" section for more info). Associated type bounds are stabilized in four positions: * **`where` clauses (and APIT)** - This is equivalent to breaking up the bound into two (or more) `where` clauses. For example, `where T: Trait<Assoc: Bound>` is equivalent to `where T: Trait, <T as Trait>::Assoc: Bound`. * **Supertraits** - Similar to above, `trait CopyIterator: Iterator<Item: Copy> {}`. This is almost equivalent to breaking up the bound into two (or more) `where` clauses; however, the bound on the associated item is implied whenever the trait is used. See rust-lang#112573/rust-lang#112629. * **Associated type item bounds** - This allows constraining the *nested* rigid projections that are associated with a trait's associated types. e.g. `trait Trait { type Assoc: Trait2<Assoc2: Copy>; }`. * **opaque item bounds (RPIT, TAIT)** - This allows constraining associated types that are associated with the opaque without having to *name* the opaque. For example, `impl Iterator<Item: Copy>` defines an iterator whose item is `Copy` without having to actually name that item bound. The latter three are not expressible in surface Rust (though for associated type item bounds, this will change in rust-lang#120752, which I don't believe should block this PR), so this does represent a slight expansion of what can be expressed in trait bounds. ### How does this differ from the RFC? Compared to the RFC, the current implementation *always* desugars associated type bounds to sets of `ty::Clause`s internally. Specifically, it does *not* introduce a position-dependent desugaring as laid out in [RFC 2289], and in particular: * It does *not* desugar to anonymous associated items in associated type item bounds. * It does *not* desugar to nested RPITs in RPIT bounds, nor nested TAITs in TAIT bounds. This position-dependent desugaring laid out in the RFC existed simply to side-step limitations of the trait solver, which have mostly been fixed in rust-lang#120584. The desugaring laid out in the RFC also added unnecessary complication to the design of the feature, and introduces its own limitations to, for example: * Conditionally lowering to nested `impl Trait` in certain positions such as RPIT and TAIT means that we inherit the limitations of RPIT/TAIT, namely lack of support for higher-ranked opaque inference. See this code example: rust-lang#120752 (comment). * Introducing anonymous associated types makes traits no longer object safe, since anonymous associated types are not nameable, and all associated types must be named in `dyn` types. This last point motivates why this PR is *not* stabilizing support for associated type bounds in `dyn` types, e.g, `dyn Assoc<Item: Bound>`. Why? Because `dyn` types need to have *concrete* types for all associated items, this would necessitate a distinct lowering for associated type bounds, which seems both complicated and unnecessary compared to just requiring the user to write `impl Trait` themselves. See rust-lang#120719. ### Implementation history: Limited to the significant behavioral changes and fixes and relevant PRs, ping me if I left something out-- * rust-lang#57428 * rust-lang#108063 * rust-lang#110512 * rust-lang#112629 * rust-lang#120719 * rust-lang#120584 Closes rust-lang#52662 [RFC 2289]: https://rust-lang.github.io/rfcs/2289-associated-type-bounds.html
Configuration menu - View commit details
-
Copy full SHA for cb1bc2c - Browse repository at this point
Copy the full SHA cb1bc2cView commit details -
Rollup merge of rust-lang#122060 - clubby789:stabilize-imported-main,…
… r=lcnr Stabilize `imported_main` FCP: rust-lang#28937 (comment) Docs: rust-lang/reference#1461
Configuration menu - View commit details
-
Copy full SHA for 9e6cee5 - Browse repository at this point
Copy the full SHA 9e6cee5View commit details -
Rollup merge of rust-lang#122370 - gurry:122199-ice-unexpected-node, …
…r=davidtwco Gracefully handle `AnonConst` in `diagnostic_hir_wf_check()` Instead of running the WF check on the `AnonConst` itself we run it on the `ty` of the generic param of which the `AnonConst` is the default value. Fixes rust-lang#122199
Configuration menu - View commit details
-
Copy full SHA for 325763c - Browse repository at this point
Copy the full SHA 325763cView commit details -
Rollup merge of rust-lang#122392 - BoxyUwU:misc_cleanup, r=lcnr
misc cleanups from debugging something rename `instantiate_canonical_with_fresh_inference_vars` to `instantiate_canonical` the substs for the canonical are not solely infer vars as that would be wildly wrong and it is rather confusing to see this method called and think that the entire canonicalization setup is completely broken when it is not 👍 also update region debug printing to be more like the custom impls for Ty/Const, right now regions in debug output are horribly verbose and make it incredibly hard to read but with this atleast boundvars and placeholders when debugging the new solver do not take up excessive amounts of space. r? `@lcnr`
Configuration menu - View commit details
-
Copy full SHA for 7c8251f - Browse repository at this point
Copy the full SHA 7c8251fView commit details -
Rollup merge of rust-lang#122642 - pallix:improve-wording-for-vec-swa…
…p_remove, r=Amanieu Improve wording of `Vec::swap_remove` This improve the wording for `Vec::swap_remove`.
Configuration menu - View commit details
-
Copy full SHA for 62de306 - Browse repository at this point
Copy the full SHA 62de306View commit details -
Rollup merge of rust-lang#122675 - tmfink:doc-clarify, r=scottmcm
core: document default attribute stabilization As of now, the first release which stabilized the `#[default]` macro for the deriving the `Default` trait for enus is not documented. I have had to search the [`RELEASES.md`](https://github.com/rust-lang/rust/blob/master/RELEASES.md) when making sure my code would be accepted by an older Rust compiler. I just added a line in the doc comment since, as far as I know, there's no option to pass to the `#[stable()]` attribute. I am open to improvements in the wording.
Configuration menu - View commit details
-
Copy full SHA for 6007cdd - Browse repository at this point
Copy the full SHA 6007cddView commit details -
Rollup merge of rust-lang#122687 - lcnr:normalizes-to-emit-nested-goa…
…ls, r=compiler-errors `NormalizesTo`: return nested goals to caller Fixes the regression of `paperclip-core`. see https://hackmd.io/IsVAafiOTAaPIFcUxRJufw for more details. r? `@compiler-errors`
Configuration menu - View commit details
-
Copy full SHA for d0e534c - Browse repository at this point
Copy the full SHA d0e534cView commit details -
Rollup merge of rust-lang#122691 - veera-sivarajan:bugfix-121099, r=A…
…manieu Fix ICE: `global_asm!()` Don't Panic When Unable to Evaluate Constant Fixes rust-lang#121099 A bit of an inelegant fix but given that the error is created only after call to `const_eval_poly()` and that the calling function cannot propagate the error anywhere else, the error has to be explicitly handled inside `mono_item.rs`. r? `@Amanieu`
Configuration menu - View commit details
-
Copy full SHA for f8a01f9 - Browse repository at this point
Copy the full SHA f8a01f9View commit details -
Rollup merge of rust-lang#122693 - ehuss:rust-css-header, r=Guillaume…
…Gomez Fix heading anchors in doc pages. This fixes the heading anchors on the standalone doc pages (the index, releases, etc.) so that the § symbol is only shown when the user hovers over the heading. This was changed in rust-lang#117662, but this CSS was not updated.
Configuration menu - View commit details
-
Copy full SHA for 0e98a61 - Browse repository at this point
Copy the full SHA 0e98a61View commit details -
Rollup merge of rust-lang#122699 - cuviper:relnotes-1.77.0-as, r=ehuss
Fix a typo in the 1.77.0 relnotes
Configuration menu - View commit details
-
Copy full SHA for 02d1965 - Browse repository at this point
Copy the full SHA 02d1965View commit details -
Rollup merge of rust-lang#122700 - esp-rs:remove-old-files, r=working…
…jubilee Remove redundant files, rename base riscv32 file Fixes a mistake I made in rust-lang#117874.
Configuration menu - View commit details
-
Copy full SHA for 1612955 - Browse repository at this point
Copy the full SHA 1612955View commit details -
Rollup merge of rust-lang#122701 - compiler-errors:allocator-suspend,…
… r=oli-obk Detect allocator for box in `must_not_suspend` lint I don't expect this to happen in practice, but better to check than not. Fixes rust-lang#122643
Configuration menu - View commit details
-
Copy full SHA for 6380d28 - Browse repository at this point
Copy the full SHA 6380d28View commit details