-
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 6 pull requests #133259
Rollup of 6 pull requests #133259
Commits on Sep 24, 2024
-
Configuration menu - View commit details
-
Copy full SHA for 26c4893 - Browse repository at this point
Copy the full SHA 26c4893View commit details
Commits on Oct 10, 2024
-
uefi: process: Add args support
- Wrap all args with quotes. - Escape ^ and " inside quotes using ^. Signed-off-by: Ayush Singh <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for 3727a8c - Browse repository at this point
Copy the full SHA 3727a8cView commit details
Commits on Oct 27, 2024
-
Configuration menu - View commit details
-
Copy full SHA for 1709a85 - Browse repository at this point
Copy the full SHA 1709a85View commit details -
Configuration menu - View commit details
-
Copy full SHA for ba12a99 - Browse repository at this point
Copy the full SHA ba12a99View commit details
Commits on Nov 17, 2024
-
Point at
const
definition when used instead of a binding in alet
…… statement After: ``` error[E0005]: refutable pattern in local binding --> $DIR/bad-pattern.rs:19:13 | LL | const PAT: u32 = 0; | -------------- missing patterns are not covered because `PAT` is interpreted as a constant pattern, not a new variable ... LL | let PAT = v1; | ^^^ | | | pattern `1_u32..=u32::MAX` not covered | help: introduce a variable instead: `PAT_var` | = note: `let` bindings require an "irrefutable pattern", like a `struct` or an `enum` with only one variant = note: for more information, visit https://doc.rust-lang.org/book/ch18-02-refutability.html = note: the matched value is of type `u32` ``` Before: ``` error[E0005]: refutable pattern in local binding --> $DIR/bad-pattern.rs:19:13 | LL | let PAT = v1; | ^^^ | | | pattern `1_u32..=u32::MAX` not covered | missing patterns are not covered because `PAT` is interpreted as a constant pattern, not a new variable | help: introduce a variable instead: `PAT_var` | = note: `let` bindings require an "irrefutable pattern", like a `struct` or an `enum` with only one variant = note: for more information, visit https://doc.rust-lang.org/book/ch18-02-refutability.html = note: the matched value is of type `u32` ```
Configuration menu - View commit details
-
Copy full SHA for ff2f7a7 - Browse repository at this point
Copy the full SHA ff2f7a7View commit details -
Configuration menu - View commit details
-
Copy full SHA for c25b44b - Browse repository at this point
Copy the full SHA c25b44bView commit details -
Configuration menu - View commit details
-
Copy full SHA for 6dc79f6 - Browse repository at this point
Copy the full SHA 6dc79f6View commit details -
Point at const when intended binding fall-through pattern is a const
``` error[E0004]: non-exhaustive patterns: `i32::MIN..=3_i32` and `5_i32..=i32::MAX` not covered --> $DIR/intended-binding-pattern-is-const.rs:2:11 | LL | match 1 { | ^ patterns `i32::MIN..=3_i32` and `5_i32..=i32::MAX` not covered LL | x => {} | - this pattern doesn't introduce a new catch-all binding, but rather pattern matches against the value of constant `x` | = note: the matched value is of type `i32` note: constant `x` defined here --> $DIR/intended-binding-pattern-is-const.rs:7:5 | LL | const x: i32 = 4; | ^^^^^^^^^^^^ help: if you meant to introduce a binding, use a different name | LL | x_var => {} | ++++ help: ensure that all possible cases are being handled by adding a match arm with a wildcard pattern, a match arm with multiple or-patterns as shown, or multiple match arms | LL | x => {}, i32::MIN..=3_i32 | 5_i32..=i32::MAX => todo!() | ++++++++++++++++++++++++++++++++++++++++++++++++ ```
Configuration menu - View commit details
-
Copy full SHA for a5b4d45 - Browse repository at this point
Copy the full SHA a5b4d45View commit details -
Configuration menu - View commit details
-
Copy full SHA for f563efe - Browse repository at this point
Copy the full SHA f563efeView commit details -
Configuration menu - View commit details
-
Copy full SHA for f1772d5 - Browse repository at this point
Copy the full SHA f1772d5View commit details -
Configuration menu - View commit details
-
Copy full SHA for bb37e5d - Browse repository at this point
Copy the full SHA bb37e5dView commit details -
- Remove check for "how many path segments is the pattern" - Check before suggesting if the path has multiple path segments
Configuration menu - View commit details
-
Copy full SHA for 6480b76 - Browse repository at this point
Copy the full SHA 6480b76View commit details -
Configuration menu - View commit details
-
Copy full SHA for 912ee65 - Browse repository at this point
Copy the full SHA 912ee65View commit details -
Configuration menu - View commit details
-
Copy full SHA for 29acf8b - Browse repository at this point
Copy the full SHA 29acf8bView commit details
Commits on Nov 20, 2024
-
Configuration menu - View commit details
-
Copy full SHA for f37d021 - Browse repository at this point
Copy the full SHA f37d021View commit details -
Configuration menu - View commit details
-
Copy full SHA for 06e66d7 - Browse repository at this point
Copy the full SHA 06e66d7View commit details -
Configuration menu - View commit details
-
Copy full SHA for 228068b - Browse repository at this point
Copy the full SHA 228068bView commit details -
Rollup merge of rust-lang#129838 - Ayush1325:uefi-process-args, r=joboet
uefi: process: Add args support - Wrap all args with quotes. - Escape ^ and " inside quotes using ^. - Doing reverse of arg parsing: https://github.com/rust-lang/rust/blob/d571ae851d93541bef826c3c48c1e9ad99da77d6/library/std/src/sys/pal/uefi/args.rs#L81 r? joboet
Configuration menu - View commit details
-
Copy full SHA for 8a8069a - Browse repository at this point
Copy the full SHA 8a8069aView commit details -
Rollup merge of rust-lang#130800 - bjoernager:const-mut-cursor, r=jos…
…htriplett Mark `get_mut` and `set_position` in `std::io::Cursor` as const. Relevant tracking issue: rust-lang#130801 The methods `get_mut` and `set_position` can trivially be marked as const due to rust-lang#57349 being stabilised.
Configuration menu - View commit details
-
Copy full SHA for ce1543f - Browse repository at this point
Copy the full SHA ce1543fView commit details -
Rollup merge of rust-lang#132207 - compiler-errors:tweak-res-mod-segm…
…ent, r=petrochenkov Store resolution for self and crate root module segments Let's make sure to record the segment resolution for `self::`, `crate::` and `$crate::`. I'm actually somewhat surprised that the only diagnostic that uses this is the one that errors on invalid generics on a module segment... but seems strictly more correct regardless, and there may be other diagnostics using these segments resolutions that just haven't been tested for `self`. Also includes a drive-by on `report_prohibit_generics_error`.
Configuration menu - View commit details
-
Copy full SHA for edf0995 - Browse repository at this point
Copy the full SHA edf0995View commit details -
Rollup merge of rust-lang#132708 - estebank:const-as-binding, r=Nadri…
…eril Point at `const` definition when used instead of a binding in a `let` statement Modify `PatKind::InlineConstant` to be `ExpandedConstant` standing in not only for inline `const` blocks but also for `const` items. This allows us to track named `const`s used in patterns when the pattern is a single binding. When we detect that there is a refutable pattern involving a `const` that could have been a binding instead, we point at the `const` item, and suggest renaming. We do this for both `let` bindings and `match` expressions missing a catch-all arm if there's at least one single binding pattern referenced. After: ``` error[E0005]: refutable pattern in local binding --> $DIR/bad-pattern.rs:19:13 | LL | const PAT: u32 = 0; | -------------- missing patterns are not covered because `PAT` is interpreted as a constant pattern, not a new variable ... LL | let PAT = v1; | ^^^ pattern `1_u32..=u32::MAX` not covered | = note: `let` bindings require an "irrefutable pattern", like a `struct` or an `enum` with only one variant = note: for more information, visit https://doc.rust-lang.org/book/ch18-02-refutability.html = note: the matched value is of type `u32` help: introduce a variable instead | LL | let PAT_var = v1; | ~~~~~~~ ``` Before: ``` error[E0005]: refutable pattern in local binding --> $DIR/bad-pattern.rs:19:13 | LL | let PAT = v1; | ^^^ | | | pattern `1_u32..=u32::MAX` not covered | missing patterns are not covered because `PAT` is interpreted as a constant pattern, not a new variable | help: introduce a variable instead: `PAT_var` | = note: `let` bindings require an "irrefutable pattern", like a `struct` or an `enum` with only one variant = note: for more information, visit https://doc.rust-lang.org/book/ch18-02-refutability.html = note: the matched value is of type `u32` ``` CC rust-lang#132582.
Configuration menu - View commit details
-
Copy full SHA for 4f53fa2 - Browse repository at this point
Copy the full SHA 4f53fa2View commit details -
Rollup merge of rust-lang#133226 - compiler-errors:opt-in-pointer-lik…
…e, r=lcnr Make `PointerLike` opt-in instead of built-in The `PointerLike` trait currently is a built-in trait that computes the layout of the type. This is a bit problematic, because types implement this trait automatically. Since this can be broken due to semver-compatible changes to a type's layout, this is undesirable. Also, calling `layout_of` in the trait system also causes cycles. This PR makes the trait implemented via regular impls, and adds additional validation on top to make sure that those impls are valid. This could eventually be `derive()`d for custom smart pointers, and we can trust *that* as a semver promise rather than risking library authors accidentally breaking it. On the other hand, we may never expose `PointerLike`, but at least now the implementation doesn't invoke `layout_of` which could cause ICEs or cause cycles. Right now for a `PointerLike` impl to be valid, it must be an ADT that is `repr(transparent)` and the non-1zst field needs to implement `PointerLike`. There are also some primitive impls for `&T`/ `&mut T`/`*const T`/`*mut T`/`Box<T>`.
Configuration menu - View commit details
-
Copy full SHA for eb9fbb0 - Browse repository at this point
Copy the full SHA eb9fbb0View commit details -
Rollup merge of rust-lang#133244 - daxpedda:wasm32v1-none-atomic, r=a…
…lexcrichton Account for `wasm32v1-none` when exporting TLS symbols Exporting TLS related symbols was limited to `wasm32-unknown-unknown` because WASI and Emscripten (?) have their own infrastructure to deal with TLS. However, the introduction of `wasm32v1-none` is in the same boat as `wasm32-unknown-unknown`. This PR adjust the mechanism to account for `wasm32v1-none` as well. See rust-lang#102385 and rust-lang#102440. r? `@alexcrichton`
Configuration menu - View commit details
-
Copy full SHA for 6199e01 - Browse repository at this point
Copy the full SHA 6199e01View commit details