Skip to content

Rollup of 11 pull requests#155061

Closed
JonathanBrouwer wants to merge 234 commits intorust-lang:mainfrom
JonathanBrouwer:rollup-xx9pxtD
Closed

Rollup of 11 pull requests#155061
JonathanBrouwer wants to merge 234 commits intorust-lang:mainfrom
JonathanBrouwer:rollup-xx9pxtD

Conversation

@JonathanBrouwer
Copy link
Copy Markdown
Contributor

Successful merges:

r? @ghost

Create a similar rollup

asukaminato0721 and others added 30 commits December 23, 2025 01:25
fix test

clippy
Example
---
```rust
trait Foo {
    fn f(&self) -> i32;

    fn foo(&self) -> i32 {
        $0self.f()+self.f()$0
    }
}
```

**Before this PR**

```rust
trait Foo {
    fn f(&self) -> i32;

    fn foo(&self) -> i32 {
        fun_name(self)
    }
}

fn $0fun_name(&self) -> i32 {
    self.f()+self.f()
}
```

**After this PR**

```rust
trait Foo {
    fn f(&self) -> i32;

    fn foo(&self) -> i32 {
        fun_name(self)
    }
}

fn $0fun_name(this: &impl Foo) -> i32 {
    this.f()+this.f()
}
```
We can't use the flycheck scope, because that value varies depending
on how the flycheck was triggered. See also
rust-lang/rust-analyzer#21571, which was reverted due to issues with
scope.

Instead, treat empty diagnostics as a flycheck for the entire
workspace, add comments explaining the JSON diagnostic format, and add
an integration test.
Example
---
```rust
trait Marker {
    fn foo();
    fn baz();
}
impl Marker for Foo {
    fn foo() {}
    fn missing() {}$0
    fn baz() {}
}
```

**Before this PR**

```rust
trait Marker {
    fn missing();
    fn foo();
    fn baz();
}
impl Marker for Foo {
    fn foo() {}
    fn missing() {}
    fn baz() {}
}
```

**After this PR**

```rust
trait Marker {
    fn foo();
    fn missing();
    fn baz();
}
impl Marker for Foo {
    fn foo() {}
    fn missing() {}
    fn baz() {}
}
```
Example
---
```rust
struct Other;
struct String;
enum Foo {
    String($0)
}
```

**Before this PR**

```text
en Foo Foo []
st Other Other []
sp Self Foo []
st String String []
```

**After this PR**

```text
st String String [name]
en Foo Foo []
st Other Other []
sp Self Foo []
```
Example
---
```rust
fn main() {
    println!("{}", env!("CA$0"));
}
```

**Before this PR**

Cannot complete any env

**After this PR**

```rust
fn main() {
    println!("{}", env!("CARGO_BIN_NAME"));
}
```
Example
---
Like `is_foo`, `.not`, `.if`

```rust
fn main() {
    let is_foo = true;
    !is_foo.$0
}
```

**Before this PR**

```rust
fn main() {
    let is_foo = true;
    !if is_foo {
        $0
    }
}
```

**After this PR**

```rust
fn main() {
    let is_foo = true;
    if !is_foo {
        $0
    }
}
```
Why? Because sometimes we work on resolving some bug that causes hang/consistent panics/stack overflows/etc., and we put it in a fixture for a test. Then r-a does exactly the same to us, and it's really hard to work this way.
This updates the rust-version file to 80ad557.
…hims

These branches reused the libc::write error string when arguments were absent.

Assisted by an AI coding tool (see CONTRIBUTING.md).

Signed-off-by: Weixie Cui <cuiweixie@gmail.com>
…ng-args-messages

fix: Correct missing-args messages for sched_getaffinity and getenv shims
For assist 'convert_to_guarded_return'

Example
---
```rust
fn main() -> i32 {
    if$0 true {
        foo();
    } else {
        bar()
    }
}
```

**Before this PR**

Assist not applicable

**After this PR**

```rust
fn main() -> i32 {
    if false {
        return bar();
    }
    foo();
}
```
…davidtwco

hwaddress: automatically add `-Ctarget-feature=+tagged-globals`

Note that since HWAddressSanitizer is/should be a target modifier, we do not have to worry about whether this LLVM target feature changes the ABI.

Fixes: rust-lang#148185
…O8Ki

Add myself as co-maintainer for hexagon-unknown-linux-musl

Two dedicated target maintainers are needed for tier 2 promotion. Coordinated with the existing maintainer r? @androm3da.
…3899, r=Kivooeo

Add tests for three fixed issues (an LLVM crash, an ICE and poor codegen)

Closes rust-lang#104037.
Closes rust-lang#112623.
Closes rust-lang#113899.
…lowering-ice, r=petrochenkov,fmease

delegation: fix unelided lifetime ICE, refactoring of GenericArgPosition

This PR does two things:
- First it restores `lower_generic_args_of_path` as it was before rust-lang#151864, as it turns out we should use `GenericArgPosition::Type` for generic args lowering for signature inheritance, as it will not cause lifetime inference and then ICEs during child args lowering,
- Next it refactors `GenericArgPosition` enum replacing `Value` and `MethodCall` with `Call(IsMethodCall)`, as the only place where we created `Value` or `MethodCall` variants was in `check_generic_arg_count_for_call`, where it was a match over `is_method_call`. Not sure it is needed, but seems cleaner to me.

Fixes rust-lang#154178, part of rust-lang#118212.

r? @petrochenkov
…thanBrouwer

minor follow up to removing soft mode `#[unstable]`

Follow up to rust-lang#153622
r? JonathanBrouwer
…adwinwhite

Fix if branch in op.rs

I removed the if guard without thinking in rust-lang#154223. Really sorry about this.

r? @hkBst
@rust-bors rust-bors bot added the rollup A PR which is a rollup label Apr 9, 2026
@rustbot rustbot added A-attributes Area: Attributes (`#[…]`, `#![…]`) A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. A-query-system Area: The rustc query system (https://rustc-dev-guide.rust-lang.org/query.html) PG-exploit-mitigations Project group: Exploit mitigations S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-rust-analyzer Relevant to the rust-analyzer team, which will review and decide on the PR/issue. labels Apr 9, 2026
@JonathanBrouwer
Copy link
Copy Markdown
Contributor Author

@bors r+ rollup=never p=5

Trying commonly failed jobs
@bors try jobs=dist-various-1,test-various,x86_64-gnu-aux,x86_64-gnu-llvm-21-3,x86_64-msvc-1,aarch64-apple,x86_64-mingw-1

@rust-bors
Copy link
Copy Markdown
Contributor

rust-bors bot commented Apr 9, 2026

📌 Commit e2e0b8e has been approved by JonathanBrouwer

It is now in the queue for this repository.

@rust-bors rust-bors bot added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Apr 9, 2026
@rust-bors
Copy link
Copy Markdown
Contributor

rust-bors bot commented Apr 9, 2026

⌛ Trying commit e2e0b8e with merge 94774df

To cancel the try build, run the command @bors try cancel.

Workflow: https://github.com/rust-lang/rust/actions/runs/24208640052

rust-bors bot pushed a commit that referenced this pull request Apr 9, 2026
Rollup of 11 pull requests


try-job: dist-various-1
try-job: test-various
try-job: x86_64-gnu-aux
try-job: x86_64-gnu-llvm-21-3
try-job: x86_64-msvc-1
try-job: aarch64-apple
try-job: x86_64-mingw-1
@rust-log-analyzer
Copy link
Copy Markdown
Collaborator

The job x86_64-gnu-llvm-21-3 failed! Check out the build log: (web) (plain enhanced) (plain)

Click to see the possible cause of the failure (guessed by this bot)
---- [ui] tests/ui/delegation/generics/generics-gen-args-errors.rs stdout ----
Saved the actual stderr to `/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/delegation/generics/generics-gen-args-errors/generics-gen-args-errors.stderr`
diff of stderr:

621 LL |         fn foo<'d: 'd, U, const M: bool>(self) {}
622    |            ^^^         -  -------------
623 
+ error[E0747]: unresolved item provided when a constant was expected
+   --> $DIR/generics-gen-args-errors.rs:34:27
+    |
+ LL |         reuse foo::<A, B, C> as xd;
+    |                           ^
+    |
+ help: if this generic argument was intended as a const parameter, surround it with braces
+    |
+ LL |         reuse foo::<A, B, { C }> as xd;
+    |                           +   +
+ 
+ error[E0747]: constant provided when a type was expected
+   --> $DIR/generics-gen-args-errors.rs:75:17
+    |
+ LL |     reuse foo::<{}, {}, {}> as bar8;
+    |                 ^^
+ 
624 error[E0107]: function takes 3 generic arguments but 6 generic arguments were supplied
625   --> $DIR/generics-gen-args-errors.rs:11:9
626    |

679    |
680 LL |         bar::<asd, asd, { asd }>();
681    |                         +     +
- 
- error[E0747]: unresolved item provided when a constant was expected
-   --> $DIR/generics-gen-args-errors.rs:34:27
-    |
- LL |         reuse foo::<A, B, C> as xd;
-    |                           ^
-    |
- help: if this generic argument was intended as a const parameter, surround it with braces
-    |
- LL |         reuse foo::<A, B, { C }> as xd;
-    |                           +   +
- 
- error[E0747]: constant provided when a type was expected
-   --> $DIR/generics-gen-args-errors.rs:75:17
-    |
- LL |     reuse foo::<{}, {}, {}> as bar8;
-    |                 ^^
699 
700 error: aborting due to 58 previous errors
701 

Note: some mismatched output was normalized before being compared
-   --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:34:27
-   --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:75:17
+ error[E0747]: unresolved item provided when a constant was expected
+   --> $DIR/generics-gen-args-errors.rs:34:27
+    |
+ LL |         reuse foo::<A, B, C> as xd;
+    |                           ^
+    |
+ help: if this generic argument was intended as a const parameter, surround it with braces
+    |
+ LL |         reuse foo::<A, B, { C }> as xd;
+    |                           +   +
+ 
+ error[E0747]: constant provided when a type was expected
+   --> $DIR/generics-gen-args-errors.rs:75:17
+    |
+ LL |     reuse foo::<{}, {}, {}> as bar8;
+    |                 ^^
+ 


The actual stderr differed from the expected stderr
To update references, rerun the tests and pass the `--bless` flag
To only update this specific test, also pass `--test-args delegation/generics/generics-gen-args-errors.rs`

error: 1 errors occurred comparing output.
status: exit status: 1
command: env -u RUSTC_LOG_COLOR RUSTC_ICE="0" RUST_BACKTRACE="short" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage1/bin/rustc" "/checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs" "-Zthreads=1" "-Zsimulate-remapped-rust-src-base=/rustc/FAKE_PREFIX" "-Ztranslate-remapped-path-to-local-path=no" "-Z" "ignore-directory-in-diagnostics-source-blocks=/cargo" "-Z" "ignore-directory-in-diagnostics-source-blocks=/checkout/vendor" "--sysroot" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage1" "--target=x86_64-unknown-linux-gnu" "--check-cfg" "cfg(test,FALSE)" "--error-format" "json" "--json" "future-incompat" "-Ccodegen-units=1" "-Zui-testing" "-Zdeduplicate-diagnostics=no" "-Zwrite-long-types-to-disk=no" "-Cstrip=debuginfo" "--emit" "metadata" "-C" "prefer-dynamic" "--out-dir" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/delegation/generics/generics-gen-args-errors" "-A" "unused" "-W" "unused_attributes" "-A" "internal_features" "-A" "incomplete_features" "-A" "unused_parens" "-A" "unused_braces" "-Crpath" "-Cdebuginfo=0" "-Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "-Z" "deduplicate-diagnostics=yes"
stdout: none
--- stderr -------------------------------
error[E0401]: can't use generic parameters from outer item
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:34:21
   |
LL |     fn check<A, B, C>() {
   |              - type parameter from outer item
...
LL |         reuse foo::<A, B, C> as xd;
   |                     ^           -- generic parameter used in this inner delegated function
   |                     |
   |                     use of generic parameter from outer item
   |
   = note: nested items are independent from their parent item for everything except for privacy and name resolution

error[E0401]: can't use generic parameters from outer item
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:34:24
   |
LL |     fn check<A, B, C>() {
   |                 - type parameter from outer item
...
LL |         reuse foo::<A, B, C> as xd;
   |                        ^        -- generic parameter used in this inner delegated function
   |                        |
   |                        use of generic parameter from outer item
   |
   = note: nested items are independent from their parent item for everything except for privacy and name resolution

error[E0401]: can't use generic parameters from outer item
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:34:27
   |
LL |     fn check<A, B, C>() {
   |                    - type parameter from outer item
...
LL |         reuse foo::<A, B, C> as xd;
   |                           ^     -- generic parameter used in this inner delegated function
   |                           |
   |                           use of generic parameter from outer item
   |
   = note: nested items are independent from their parent item for everything except for privacy and name resolution

error[E0261]: use of undeclared lifetime name `'asdasd`
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:53:29
   |
LL |     reuse foo::<'static, _, 'asdasd, 'static, 'static, 'static, _> as bar3;
   |                             ^^^^^^^ undeclared lifetime
   |
help: consider introducing lifetime `'asdasd` here
   |
LL |     reuse foo'asdasd, ::<'static, _, 'asdasd, 'static, 'static, 'static, _> as bar3;
   |              ++++++++

error[E0261]: use of undeclared lifetime name `'a`
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:70:50
   |
LL |     reuse foo::<"asdasd", asd, "askdn", 'static, 'a> as bar7;
   |                                                  ^^ undeclared lifetime
   |
help: consider introducing lifetime `'a` here
   |
LL |     reuse foo'a, ::<"asdasd", asd, "askdn", 'static, 'a> as bar7;
   |              +++

error[E0106]: missing lifetime specifiers
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:117:19
   |
LL |     reuse Trait::<Trait, Clone, _, 'static, dyn Send, _>::foo::<1, 2, 3, _, 6> as bar7;
   |                   ^^^^^ expected 3 lifetime parameters
   |
help: consider introducing a named lifetime parameter
   |
LL |     reuse Trait::<Trait<'a, 'a, 'a>, Clone, _, 'static, dyn Send, _>::foo'a, ::<1, 2, 3, _, 6> as bar7;
   |                        ++++++++++++                                      +++

error[E0423]: expected value, found struct `String`
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:14:33
   |
LL |         bar::<String, String, { String }>();
   |                                 ^^^^^^
   |
  --> /rustc/FAKE_PREFIX/library/alloc/src/string.rs:353:0
   |
   = note: `String` defined here

error[E0425]: cannot find type `asd` in this scope
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:28:15
   |
LL |         bar::<asd, asd, asd>();
   |               ^^^ not found in this scope
   |
help: you might be missing a type parameter
   |
LL |     fn check<A, B, C, asd>() {
   |                     +++++

error[E0425]: cannot find type `asd` in this scope
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:28:20
   |
LL |         bar::<asd, asd, asd>();
   |                    ^^^ not found in this scope
   |
help: you might be missing a type parameter
   |
LL |     fn check<A, B, C, asd>() {
   |                     +++++

error[E0425]: cannot find type `asd` in this scope
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:28:25
   |
LL |         bar::<asd, asd, asd>();
   |                         ^^^ not found in this scope
   |
help: you might be missing a type parameter
   |
LL |     fn check<A, B, C, asd>() {
   |                     +++++

error[E0425]: cannot find type `asdasd` in this scope
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:57:39
   |
LL |     reuse foo::<String, 'static, 123, asdasd> as bar4;
   |                                       ^^^^^^ not found in this scope

error[E0425]: cannot find type `asd` in this scope
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:65:22
   |
LL |     reuse foo::<1, 2,asd,String, { let x = 0; }> as bar6;
   |                      ^^^ not found in this scope

error[E0425]: cannot find type `asd` in this scope
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:70:27
   |
LL |     reuse foo::<"asdasd", asd, "askdn", 'static, 'a> as bar7;
   |                           ^^^ not found in this scope

error[E0425]: cannot find type `asd` in this scope
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:85:19
   |
LL |     reuse Trait::<asd, asd, asd, asd, asd, asdasa>::foo as bar1;
   |                   ^^^ not found in this scope

error[E0425]: cannot find type `asd` in this scope
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:85:24
   |
LL |     reuse Trait::<asd, asd, asd, asd, asd, asdasa>::foo as bar1;
   |                        ^^^ not found in this scope

error[E0425]: cannot find type `asd` in this scope
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:85:29
   |
LL |     reuse Trait::<asd, asd, asd, asd, asd, asdasa>::foo as bar1;
   |                             ^^^ not found in this scope

error[E0425]: cannot find type `asd` in this scope
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:85:34
   |
LL |     reuse Trait::<asd, asd, asd, asd, asd, asdasa>::foo as bar1;
   |                                  ^^^ not found in this scope

error[E0425]: cannot find type `asd` in this scope
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:85:39
   |
LL |     reuse Trait::<asd, asd, asd, asd, asd, asdasa>::foo as bar1;
   |                                       ^^^ not found in this scope

error[E0425]: cannot find type `asdasa` in this scope
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:85:44
   |
LL |     reuse Trait::<asd, asd, asd, asd, asd, asdasa>::foo as bar1;
   |                                            ^^^^^^ not found in this scope

error[E0425]: cannot find type `DDDD` in this scope
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:110:34
   |
LL |     reuse Trait::<1, 2, 'static, DDDD>::foo::<1, 2, 3, 4, 5, 6> as bar6;
   |                                  ^^^^ not found in this scope

error[E0107]: function takes 2 lifetime arguments but 0 lifetime arguments were supplied
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:34:15
   |
LL |         reuse foo::<A, B, C> as xd;
   |               ^^^ expected 2 lifetime arguments
   |
note: function defined here, with 2 lifetime parameters: `'a`, `'b`
  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:7:8
   |
LL |     fn foo<'a: 'a, 'b: 'b, T: Clone, U: Clone, const N: usize>() {}
   |        ^^^ --      --
help: add missing lifetime arguments
   |
LL |         reuse foo::<'a, 'b, A, B, C> as xd;
   |                     +++++++

error[E0121]: the placeholder `_` is not allowed within types on item signatures for functions
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:46:11
   |
LL |     reuse foo::<> as bar1;
   |           ^^^ not allowed in type signatures

error[E0107]: function takes 2 lifetime arguments but 0 lifetime arguments were supplied
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:49:11
   |
LL |     reuse foo::<String, String> as bar2;
   |           ^^^ expected 2 lifetime arguments
   |
note: function defined here, with 2 lifetime parameters: `'a`, `'b`
  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:44:8
   |
LL |     fn foo<'a: 'a, 'b: 'b, T: Clone, U: Clone, const N: usize>() {}
   |        ^^^ --      --
help: add missing lifetime arguments
   |
LL |     reuse foo::<'a, 'b, String, String> as bar2;
   |                 +++++++

error[E0107]: function takes 3 generic arguments but 2 generic arguments were supplied
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:49:11
   |
LL |     reuse foo::<String, String> as bar2;
   |           ^^^   ------  ------ supplied 2 generic arguments
   |           |
   |           expected 3 generic arguments
   |
note: function defined here, with 3 generic parameters: `T`, `U`, `N`
  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:44:8
   |
LL |     fn foo<'a: 'a, 'b: 'b, T: Clone, U: Clone, const N: usize>() {}
   |        ^^^                 -         -         --------------
help: add missing generic argument
   |
LL |     reuse foo::<String, String, N> as bar2;
   |                               +++

error[E0107]: function takes 2 lifetime arguments but 5 lifetime arguments were supplied
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:53:11
   |
LL |     reuse foo::<'static, _, 'asdasd, 'static, 'static, 'static, _> as bar3;
   |           ^^^                      --------------------------- help: remove the lifetime arguments
   |           |
   |           expected 2 lifetime arguments
   |
note: function defined here, with 2 lifetime parameters: `'a`, `'b`
  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:44:8
   |
LL |     fn foo<'a: 'a, 'b: 'b, T: Clone, U: Clone, const N: usize>() {}
   |        ^^^ --      --

error[E0107]: function takes 3 generic arguments but 2 generic arguments were supplied
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:53:11
   |
LL |     reuse foo::<'static, _, 'asdasd, 'static, 'static, 'static, _> as bar3;
   |           ^^^ expected 3 generic arguments             -------  - supplied 2 generic arguments
   |
note: function defined here, with 3 generic parameters: `T`, `U`, `N`
  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:44:8
   |
LL |     fn foo<'a: 'a, 'b: 'b, T: Clone, U: Clone, const N: usize>() {}
   |        ^^^                 -         -         --------------
help: add missing generic argument
   |
LL |     reuse foo::<'static, _, 'asdasd, 'static, 'static, 'static, _, N> as bar3;
   |                                                                  +++

error[E0107]: function takes 2 lifetime arguments but 1 lifetime argument was supplied
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:57:11
   |
LL |     reuse foo::<String, 'static, 123, asdasd> as bar4;
   |           ^^^   ------ supplied 1 lifetime argument
   |           |
   |           expected 2 lifetime arguments
   |
note: function defined here, with 2 lifetime parameters: `'a`, `'b`
  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:44:8
   |
LL |     fn foo<'a: 'a, 'b: 'b, T: Clone, U: Clone, const N: usize>() {}
   |        ^^^ --      --
help: add missing lifetime argument
   |
LL |     reuse foo::<String, 'static, 'static, 123, asdasd> as bar4;
   |                       +++++++++

error[E0107]: function takes 2 lifetime arguments but 0 lifetime arguments were supplied
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:61:11
   |
LL |     reuse foo::<1, 2, _, 4, 5, _> as bar5;
   |           ^^^ expected 2 lifetime arguments
   |
note: function defined here, with 2 lifetime parameters: `'a`, `'b`
  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:44:8
   |
LL |     fn foo<'a: 'a, 'b: 'b, T: Clone, U: Clone, const N: usize>() {}
   |        ^^^ --      --
help: add missing lifetime arguments
   |
LL |     reuse foo::<'a, 'b, 1, 2, _, 4, 5, _> as bar5;
   |                 +++++++

error[E0107]: function takes 3 generic arguments but 6 generic arguments were supplied
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:61:11
   |
LL |     reuse foo::<1, 2, _, 4, 5, _> as bar5;
   |           ^^^          --------- help: remove the unnecessary generic arguments
   |           |
   |           expected 3 generic arguments
   |
note: function defined here, with 3 generic parameters: `T`, `U`, `N`
  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:44:8
   |
LL |     fn foo<'a: 'a, 'b: 'b, T: Clone, U: Clone, const N: usize>() {}
   |        ^^^                 -         -         --------------

error[E0107]: function takes 2 lifetime arguments but 0 lifetime arguments were supplied
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:65:11
   |
LL |     reuse foo::<1, 2,asd,String, { let x = 0; }> as bar6;
   |           ^^^ expected 2 lifetime arguments
   |
note: function defined here, with 2 lifetime parameters: `'a`, `'b`
  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:44:8
   |
LL |     fn foo<'a: 'a, 'b: 'b, T: Clone, U: Clone, const N: usize>() {}
   |        ^^^ --      --
help: add missing lifetime arguments
   |
LL |     reuse foo::<'a, 'b, 1, 2,asd,String, { let x = 0; }> as bar6;
   |                 +++++++

error[E0107]: function takes 3 generic arguments but 5 generic arguments were supplied
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:65:11
   |
LL |     reuse foo::<1, 2,asd,String, { let x = 0; }> as bar6;
   |           ^^^           ----------------------- help: remove the unnecessary generic arguments
   |           |
   |           expected 3 generic arguments
   |
note: function defined here, with 3 generic parameters: `T`, `U`, `N`
  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:44:8
   |
LL |     fn foo<'a: 'a, 'b: 'b, T: Clone, U: Clone, const N: usize>() {}
   |        ^^^                 -         -         --------------

error[E0747]: constant provided when a type was expected
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:70:17
   |
LL |     reuse foo::<"asdasd", asd, "askdn", 'static, 'a> as bar7;
   |                 ^^^^^^^^

error[E0107]: function takes 2 lifetime arguments but 0 lifetime arguments were supplied
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:75:11
   |
LL |     reuse foo::<{}, {}, {}> as bar8;
   |           ^^^ expected 2 lifetime arguments
   |
note: function defined here, with 2 lifetime parameters: `'a`, `'b`
  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:44:8
   |
LL |     fn foo<'a: 'a, 'b: 'b, T: Clone, U: Clone, const N: usize>() {}
   |        ^^^ --      --
help: add missing lifetime arguments
   |
LL |     reuse foo::<'a, 'b, {}, {}, {}> as bar8;
   |                 +++++++

error[E0107]: trait takes 3 lifetime arguments but 0 lifetime arguments were supplied
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:85:11
   |
LL |     reuse Trait::<asd, asd, asd, asd, asd, asdasa>::foo as bar1;
   |           ^^^^^ expected 3 lifetime arguments
   |
note: trait defined here, with 3 lifetime parameters: `'b`, `'c`, `'a`
  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:81:11
   |
LL |     trait Trait<'b, 'c, 'a, T, const N: usize>: Sized {
   |           ^^^^^ --  --  --
help: add missing lifetime arguments
   |
LL |     reuse Trait::<'b, 'c, 'a, asd, asd, asd, asd, asd, asdasa>::foo as bar1;
   |                   +++++++++++

error[E0107]: trait takes 2 generic arguments but 6 generic arguments were supplied
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:85:11
   |
LL |     reuse Trait::<asd, asd, asd, asd, asd, asdasa>::foo as bar1;
   |           ^^^^^           ----------------------- help: remove the unnecessary generic arguments
   |           |
   |           expected 2 generic arguments
   |
note: trait defined here, with 2 generic parameters: `T`, `N`
  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:81:11
   |
LL |     trait Trait<'b, 'c, 'a, T, const N: usize>: Sized {
   |           ^^^^^             -  --------------

error[E0107]: trait takes 3 lifetime arguments but 2 lifetime arguments were supplied
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:95:11
   |
LL |     reuse Trait::<'static, 'static>::foo as bar2;
   |           ^^^^^   -------  ------- supplied 2 lifetime arguments
   |           |
   |           expected 3 lifetime arguments
   |
note: trait defined here, with 3 lifetime parameters: `'b`, `'c`, `'a`
  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:81:11
   |
LL |     trait Trait<'b, 'c, 'a, T, const N: usize>: Sized {
   |           ^^^^^ --  --  --
help: add missing lifetime argument
   |
LL |     reuse Trait::<'static, 'static, 'static>::foo as bar2;
   |                                   +++++++++

error[E0121]: the placeholder `_` is not allowed within types on item signatures for functions
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:95:11
   |
LL |     reuse Trait::<'static, 'static>::foo as bar2;
   |           ^^^^^ not allowed in type signatures

error[E0107]: trait takes 3 lifetime arguments but 0 lifetime arguments were supplied
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:98:11

@rust-log-analyzer
Copy link
Copy Markdown
Collaborator

The job aarch64-gnu-llvm-21-1 failed! Check out the build log: (web) (plain enhanced) (plain)

Click to see the possible cause of the failure (guessed by this bot)
##[endgroup]
Executing "/scripts/stage_2_test_set1.sh"
+ /scripts/stage_2_test_set1.sh
+ '[' 1 == 1 ']'
+ echo 'PR_CI_JOB set; skipping tidy'
+ SKIP_TIDY='--skip tidy'
+ ../x.py --stage 2 test --skip tidy --skip compiler --skip src
PR_CI_JOB set; skipping tidy
##[group]Building bootstrap
    Finished `dev` profile [unoptimized] target(s) in 0.04s
##[endgroup]
---
---- [ui] tests/ui/delegation/generics/generics-gen-args-errors.rs stdout ----
Saved the actual stderr to `/checkout/obj/build/aarch64-unknown-linux-gnu/test/ui/delegation/generics/generics-gen-args-errors/generics-gen-args-errors.stderr`
diff of stderr:

621 LL |         fn foo<'d: 'd, U, const M: bool>(self) {}
622    |            ^^^         -  -------------
623 
+ error[E0747]: unresolved item provided when a constant was expected
+   --> $DIR/generics-gen-args-errors.rs:34:27
+    |
+ LL |         reuse foo::<A, B, C> as xd;
+    |                           ^
+    |
+ help: if this generic argument was intended as a const parameter, surround it with braces
+    |
+ LL |         reuse foo::<A, B, { C }> as xd;
+    |                           +   +
+ 
+ error[E0747]: constant provided when a type was expected
+   --> $DIR/generics-gen-args-errors.rs:75:17
+    |
+ LL |     reuse foo::<{}, {}, {}> as bar8;
+    |                 ^^
+ 
624 error[E0107]: function takes 3 generic arguments but 6 generic arguments were supplied
625   --> $DIR/generics-gen-args-errors.rs:11:9
626    |

679    |
680 LL |         bar::<asd, asd, { asd }>();
681    |                         +     +
- 
- error[E0747]: unresolved item provided when a constant was expected
-   --> $DIR/generics-gen-args-errors.rs:34:27
-    |
- LL |         reuse foo::<A, B, C> as xd;
-    |                           ^
-    |
- help: if this generic argument was intended as a const parameter, surround it with braces
-    |
- LL |         reuse foo::<A, B, { C }> as xd;
-    |                           +   +
- 
- error[E0747]: constant provided when a type was expected
-   --> $DIR/generics-gen-args-errors.rs:75:17
-    |
- LL |     reuse foo::<{}, {}, {}> as bar8;
-    |                 ^^
699 
700 error: aborting due to 58 previous errors
701 

Note: some mismatched output was normalized before being compared
-   --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:34:27
-   --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:75:17
+ error[E0747]: unresolved item provided when a constant was expected
+   --> $DIR/generics-gen-args-errors.rs:34:27
+    |
+ LL |         reuse foo::<A, B, C> as xd;
+    |                           ^
+    |
+ help: if this generic argument was intended as a const parameter, surround it with braces
+    |
+ LL |         reuse foo::<A, B, { C }> as xd;
+    |                           +   +
+ 
+ error[E0747]: constant provided when a type was expected
+   --> $DIR/generics-gen-args-errors.rs:75:17
+    |
+ LL |     reuse foo::<{}, {}, {}> as bar8;
+    |                 ^^
+ 


The actual stderr differed from the expected stderr
To update references, rerun the tests and pass the `--bless` flag
To only update this specific test, also pass `--test-args delegation/generics/generics-gen-args-errors.rs`

error: 1 errors occurred comparing output.
status: exit status: 1
command: env -u RUSTC_LOG_COLOR RUSTC_ICE="0" RUST_BACKTRACE="short" "/checkout/obj/build/aarch64-unknown-linux-gnu/stage2/bin/rustc" "/checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs" "-Zthreads=1" "-Zsimulate-remapped-rust-src-base=/rustc/FAKE_PREFIX" "-Ztranslate-remapped-path-to-local-path=no" "-Z" "ignore-directory-in-diagnostics-source-blocks=/cargo" "-Z" "ignore-directory-in-diagnostics-source-blocks=/checkout/vendor" "--sysroot" "/checkout/obj/build/aarch64-unknown-linux-gnu/stage2" "--target=aarch64-unknown-linux-gnu" "--check-cfg" "cfg(test,FALSE)" "--error-format" "json" "--json" "future-incompat" "-Ccodegen-units=1" "-Zui-testing" "-Zdeduplicate-diagnostics=no" "-Zwrite-long-types-to-disk=no" "-Cstrip=debuginfo" "--emit" "metadata" "-C" "prefer-dynamic" "--out-dir" "/checkout/obj/build/aarch64-unknown-linux-gnu/test/ui/delegation/generics/generics-gen-args-errors" "-A" "unused" "-W" "unused_attributes" "-A" "internal_features" "-A" "incomplete_features" "-A" "unused_parens" "-A" "unused_braces" "-Crpath" "-Cdebuginfo=0" "-Lnative=/checkout/obj/build/aarch64-unknown-linux-gnu/native/rust-test-helpers" "-Z" "deduplicate-diagnostics=yes"
stdout: none
--- stderr -------------------------------
error[E0401]: can't use generic parameters from outer item
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:34:21
   |
LL |     fn check<A, B, C>() {
   |              - type parameter from outer item
...
LL |         reuse foo::<A, B, C> as xd;
   |                     ^           -- generic parameter used in this inner delegated function
   |                     |
   |                     use of generic parameter from outer item
   |
   = note: nested items are independent from their parent item for everything except for privacy and name resolution

error[E0401]: can't use generic parameters from outer item
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:34:24
   |
LL |     fn check<A, B, C>() {
   |                 - type parameter from outer item
...
LL |         reuse foo::<A, B, C> as xd;
   |                        ^        -- generic parameter used in this inner delegated function
   |                        |
   |                        use of generic parameter from outer item
   |
   = note: nested items are independent from their parent item for everything except for privacy and name resolution

error[E0401]: can't use generic parameters from outer item
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:34:27
   |
LL |     fn check<A, B, C>() {
   |                    - type parameter from outer item
...
LL |         reuse foo::<A, B, C> as xd;
   |                           ^     -- generic parameter used in this inner delegated function
   |                           |
   |                           use of generic parameter from outer item
   |
   = note: nested items are independent from their parent item for everything except for privacy and name resolution

error[E0261]: use of undeclared lifetime name `'asdasd`
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:53:29
   |
LL |     reuse foo::<'static, _, 'asdasd, 'static, 'static, 'static, _> as bar3;
   |                             ^^^^^^^ undeclared lifetime
   |
help: consider introducing lifetime `'asdasd` here
   |
LL |     reuse foo'asdasd, ::<'static, _, 'asdasd, 'static, 'static, 'static, _> as bar3;
   |              ++++++++

error[E0261]: use of undeclared lifetime name `'a`
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:70:50
   |
LL |     reuse foo::<"asdasd", asd, "askdn", 'static, 'a> as bar7;
   |                                                  ^^ undeclared lifetime
   |
help: consider introducing lifetime `'a` here
   |
LL |     reuse foo'a, ::<"asdasd", asd, "askdn", 'static, 'a> as bar7;
   |              +++

error[E0106]: missing lifetime specifiers
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:117:19
   |
LL |     reuse Trait::<Trait, Clone, _, 'static, dyn Send, _>::foo::<1, 2, 3, _, 6> as bar7;
   |                   ^^^^^ expected 3 lifetime parameters
   |
help: consider introducing a named lifetime parameter
   |
LL |     reuse Trait::<Trait<'a, 'a, 'a>, Clone, _, 'static, dyn Send, _>::foo'a, ::<1, 2, 3, _, 6> as bar7;
   |                        ++++++++++++                                      +++

error[E0423]: expected value, found struct `String`
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:14:33
   |
LL |         bar::<String, String, { String }>();
   |                                 ^^^^^^
   |
  --> /rustc/FAKE_PREFIX/library/alloc/src/string.rs:353:0
   |
   = note: `String` defined here

error[E0425]: cannot find type `asd` in this scope
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:28:15
   |
LL |         bar::<asd, asd, asd>();
   |               ^^^ not found in this scope
   |
help: you might be missing a type parameter
   |
LL |     fn check<A, B, C, asd>() {
   |                     +++++

error[E0425]: cannot find type `asd` in this scope
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:28:20
   |
LL |         bar::<asd, asd, asd>();
   |                    ^^^ not found in this scope
   |
help: you might be missing a type parameter
   |
LL |     fn check<A, B, C, asd>() {
   |                     +++++

error[E0425]: cannot find type `asd` in this scope
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:28:25
   |
LL |         bar::<asd, asd, asd>();
   |                         ^^^ not found in this scope
   |
help: you might be missing a type parameter
   |
LL |     fn check<A, B, C, asd>() {
   |                     +++++

error[E0425]: cannot find type `asdasd` in this scope
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:57:39
   |
LL |     reuse foo::<String, 'static, 123, asdasd> as bar4;
   |                                       ^^^^^^ not found in this scope

error[E0425]: cannot find type `asd` in this scope
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:65:22
   |
LL |     reuse foo::<1, 2,asd,String, { let x = 0; }> as bar6;
   |                      ^^^ not found in this scope

error[E0425]: cannot find type `asd` in this scope
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:70:27
   |
LL |     reuse foo::<"asdasd", asd, "askdn", 'static, 'a> as bar7;
   |                           ^^^ not found in this scope

error[E0425]: cannot find type `asd` in this scope
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:85:19
   |
LL |     reuse Trait::<asd, asd, asd, asd, asd, asdasa>::foo as bar1;
   |                   ^^^ not found in this scope

error[E0425]: cannot find type `asd` in this scope
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:85:24
   |
LL |     reuse Trait::<asd, asd, asd, asd, asd, asdasa>::foo as bar1;
   |                        ^^^ not found in this scope

error[E0425]: cannot find type `asd` in this scope
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:85:29
   |
LL |     reuse Trait::<asd, asd, asd, asd, asd, asdasa>::foo as bar1;
   |                             ^^^ not found in this scope

error[E0425]: cannot find type `asd` in this scope
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:85:34
   |
LL |     reuse Trait::<asd, asd, asd, asd, asd, asdasa>::foo as bar1;
   |                                  ^^^ not found in this scope

error[E0425]: cannot find type `asd` in this scope
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:85:39
   |
LL |     reuse Trait::<asd, asd, asd, asd, asd, asdasa>::foo as bar1;
   |                                       ^^^ not found in this scope

error[E0425]: cannot find type `asdasa` in this scope
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:85:44
   |
LL |     reuse Trait::<asd, asd, asd, asd, asd, asdasa>::foo as bar1;
   |                                            ^^^^^^ not found in this scope

error[E0425]: cannot find type `DDDD` in this scope
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:110:34
   |
LL |     reuse Trait::<1, 2, 'static, DDDD>::foo::<1, 2, 3, 4, 5, 6> as bar6;
   |                                  ^^^^ not found in this scope

error[E0107]: function takes 2 lifetime arguments but 0 lifetime arguments were supplied
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:34:15
   |
LL |         reuse foo::<A, B, C> as xd;
   |               ^^^ expected 2 lifetime arguments
   |
note: function defined here, with 2 lifetime parameters: `'a`, `'b`
  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:7:8
   |
LL |     fn foo<'a: 'a, 'b: 'b, T: Clone, U: Clone, const N: usize>() {}
   |        ^^^ --      --
help: add missing lifetime arguments
   |
LL |         reuse foo::<'a, 'b, A, B, C> as xd;
   |                     +++++++

error[E0121]: the placeholder `_` is not allowed within types on item signatures for functions
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:46:11
   |
LL |     reuse foo::<> as bar1;
   |           ^^^ not allowed in type signatures

error[E0107]: function takes 2 lifetime arguments but 0 lifetime arguments were supplied
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:49:11
   |
LL |     reuse foo::<String, String> as bar2;
   |           ^^^ expected 2 lifetime arguments
   |
note: function defined here, with 2 lifetime parameters: `'a`, `'b`
  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:44:8
   |
LL |     fn foo<'a: 'a, 'b: 'b, T: Clone, U: Clone, const N: usize>() {}
   |        ^^^ --      --
help: add missing lifetime arguments
   |
LL |     reuse foo::<'a, 'b, String, String> as bar2;
   |                 +++++++

error[E0107]: function takes 3 generic arguments but 2 generic arguments were supplied
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:49:11
   |
LL |     reuse foo::<String, String> as bar2;
   |           ^^^   ------  ------ supplied 2 generic arguments
   |           |
   |           expected 3 generic arguments
   |
note: function defined here, with 3 generic parameters: `T`, `U`, `N`
  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:44:8
   |
LL |     fn foo<'a: 'a, 'b: 'b, T: Clone, U: Clone, const N: usize>() {}
   |        ^^^                 -         -         --------------
help: add missing generic argument
   |
LL |     reuse foo::<String, String, N> as bar2;
   |                               +++

error[E0107]: function takes 2 lifetime arguments but 5 lifetime arguments were supplied
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:53:11
   |
LL |     reuse foo::<'static, _, 'asdasd, 'static, 'static, 'static, _> as bar3;
   |           ^^^                      --------------------------- help: remove the lifetime arguments
   |           |
   |           expected 2 lifetime arguments
   |
note: function defined here, with 2 lifetime parameters: `'a`, `'b`
  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:44:8
   |
LL |     fn foo<'a: 'a, 'b: 'b, T: Clone, U: Clone, const N: usize>() {}
   |        ^^^ --      --

error[E0107]: function takes 3 generic arguments but 2 generic arguments were supplied
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:53:11
   |
LL |     reuse foo::<'static, _, 'asdasd, 'static, 'static, 'static, _> as bar3;
   |           ^^^ expected 3 generic arguments             -------  - supplied 2 generic arguments
   |
note: function defined here, with 3 generic parameters: `T`, `U`, `N`
  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:44:8
   |
LL |     fn foo<'a: 'a, 'b: 'b, T: Clone, U: Clone, const N: usize>() {}
   |        ^^^                 -         -         --------------
help: add missing generic argument
   |
LL |     reuse foo::<'static, _, 'asdasd, 'static, 'static, 'static, _, N> as bar3;
   |                                                                  +++

error[E0107]: function takes 2 lifetime arguments but 1 lifetime argument was supplied
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:57:11
   |
LL |     reuse foo::<String, 'static, 123, asdasd> as bar4;
   |           ^^^   ------ supplied 1 lifetime argument
   |           |
   |           expected 2 lifetime arguments
   |
note: function defined here, with 2 lifetime parameters: `'a`, `'b`
  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:44:8
   |
LL |     fn foo<'a: 'a, 'b: 'b, T: Clone, U: Clone, const N: usize>() {}
   |        ^^^ --      --
help: add missing lifetime argument
   |
LL |     reuse foo::<String, 'static, 'static, 123, asdasd> as bar4;
   |                       +++++++++

error[E0107]: function takes 2 lifetime arguments but 0 lifetime arguments were supplied
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:61:11
   |
LL |     reuse foo::<1, 2, _, 4, 5, _> as bar5;
   |           ^^^ expected 2 lifetime arguments
   |
note: function defined here, with 2 lifetime parameters: `'a`, `'b`
  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:44:8
   |
LL |     fn foo<'a: 'a, 'b: 'b, T: Clone, U: Clone, const N: usize>() {}
   |        ^^^ --      --
help: add missing lifetime arguments
   |
LL |     reuse foo::<'a, 'b, 1, 2, _, 4, 5, _> as bar5;
   |                 +++++++

error[E0107]: function takes 3 generic arguments but 6 generic arguments were supplied
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:61:11
   |
LL |     reuse foo::<1, 2, _, 4, 5, _> as bar5;
   |           ^^^          --------- help: remove the unnecessary generic arguments
   |           |
   |           expected 3 generic arguments
   |
note: function defined here, with 3 generic parameters: `T`, `U`, `N`
  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:44:8
   |
LL |     fn foo<'a: 'a, 'b: 'b, T: Clone, U: Clone, const N: usize>() {}
   |        ^^^                 -         -         --------------

error[E0107]: function takes 2 lifetime arguments but 0 lifetime arguments were supplied
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:65:11
   |
LL |     reuse foo::<1, 2,asd,String, { let x = 0; }> as bar6;
   |           ^^^ expected 2 lifetime arguments
   |
note: function defined here, with 2 lifetime parameters: `'a`, `'b`
  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:44:8
   |
LL |     fn foo<'a: 'a, 'b: 'b, T: Clone, U: Clone, const N: usize>() {}
   |        ^^^ --      --
help: add missing lifetime arguments
   |
LL |     reuse foo::<'a, 'b, 1, 2,asd,String, { let x = 0; }> as bar6;
   |                 +++++++

error[E0107]: function takes 3 generic arguments but 5 generic arguments were supplied
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:65:11
   |
LL |     reuse foo::<1, 2,asd,String, { let x = 0; }> as bar6;
   |           ^^^           ----------------------- help: remove the unnecessary generic arguments
   |           |
   |           expected 3 generic arguments
   |
note: function defined here, with 3 generic parameters: `T`, `U`, `N`
  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:44:8
   |
LL |     fn foo<'a: 'a, 'b: 'b, T: Clone, U: Clone, const N: usize>() {}
   |        ^^^                 -         -         --------------

error[E0747]: constant provided when a type was expected
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:70:17
   |
LL |     reuse foo::<"asdasd", asd, "askdn", 'static, 'a> as bar7;
   |                 ^^^^^^^^

error[E0107]: function takes 2 lifetime arguments but 0 lifetime arguments were supplied
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:75:11
   |
LL |     reuse foo::<{}, {}, {}> as bar8;
   |           ^^^ expected 2 lifetime arguments
   |
note: function defined here, with 2 lifetime parameters: `'a`, `'b`
  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:44:8
   |
LL |     fn foo<'a: 'a, 'b: 'b, T: Clone, U: Clone, const N: usize>() {}
   |        ^^^ --      --
help: add missing lifetime arguments
   |
LL |     reuse foo::<'a, 'b, {}, {}, {}> as bar8;
   |                 +++++++

error[E0107]: trait takes 3 lifetime arguments but 0 lifetime arguments were supplied
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:85:11
   |
LL |     reuse Trait::<asd, asd, asd, asd, asd, asdasa>::foo as bar1;
   |           ^^^^^ expected 3 lifetime arguments
   |
note: trait defined here, with 3 lifetime parameters: `'b`, `'c`, `'a`
  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:81:11
   |
LL |     trait Trait<'b, 'c, 'a, T, const N: usize>: Sized {
   |           ^^^^^ --  --  --
help: add missing lifetime arguments
   |
LL |     reuse Trait::<'b, 'c, 'a, asd, asd, asd, asd, asd, asdasa>::foo as bar1;
   |                   +++++++++++

error[E0107]: trait takes 2 generic arguments but 6 generic arguments were supplied
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:85:11
   |
LL |     reuse Trait::<asd, asd, asd, asd, asd, asdasa>::foo as bar1;
   |           ^^^^^           ----------------------- help: remove the unnecessary generic arguments
   |           |
   |           expected 2 generic arguments
   |
note: trait defined here, with 2 generic parameters: `T`, `N`
  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:81:11
   |
LL |     trait Trait<'b, 'c, 'a, T, const N: usize>: Sized {
   |           ^^^^^             -  --------------

error[E0107]: trait takes 3 lifetime arguments but 2 lifetime arguments were supplied
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:95:11
   |
LL |     reuse Trait::<'static, 'static>::foo as bar2;
   |           ^^^^^   -------  ------- supplied 2 lifetime arguments
   |           |
   |           expected 3 lifetime arguments
   |
note: trait defined here, with 3 lifetime parameters: `'b`, `'c`, `'a`
  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:81:11
   |
LL |     trait Trait<'b, 'c, 'a, T, const N: usize>: Sized {
   |           ^^^^^ --  --  --
help: add missing lifetime argument
   |
LL |     reuse Trait::<'static, 'static, 'static>::foo as bar2;
   |                                   +++++++++

error[E0121]: the placeholder `_` is not allowed within types on item signatures for functions
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:95:11
   |
LL |     reuse Trait::<'static, 'static>::foo as bar2;
   |           ^^^^^ not allowed in type signatures

error[E0107]: trait takes 3 lifetime arguments but 0 lifetime arguments were supplied
##[error]  --> /checkout/tests/ui/delegation/generics/generics-gen-args-errors.rs:98:11

@rust-bors rust-bors bot added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Apr 9, 2026
@rust-bors
Copy link
Copy Markdown
Contributor

rust-bors bot commented Apr 9, 2026

PR #155031, which is a member of this rollup, was unapproved.

This rollup was thus unapproved.

@JonathanBrouwer
Copy link
Copy Markdown
Contributor Author

@bors try cancel

@rustbot rustbot removed the S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. label Apr 9, 2026
@rust-bors
Copy link
Copy Markdown
Contributor

rust-bors bot commented Apr 9, 2026

Try build cancelled. Cancelled workflows:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-attributes Area: Attributes (`#[…]`, `#![…]`) A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. A-query-system Area: The rustc query system (https://rustc-dev-guide.rust-lang.org/query.html) PG-exploit-mitigations Project group: Exploit mitigations rollup A PR which is a rollup T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-rust-analyzer Relevant to the rust-analyzer team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.