Open
Description
auto-reduced (treereduce-rust):
#![feature(non_lifetime_binders)]
trait Trait<T: ?Sized> {
type Assoc<'a> = i32;
}
fn produce() -> impl for<T> Trait<(), Assoc = impl Trait<T>> {
16
}
original:
#![allow(incomplete_features)]
#![feature(non_lifetime_binders)]
trait Trait<T: ?Sized> {
type Assoc<'a> = i32;
fn with_assoc(f: impl FnOnce(Self::Assoc<'_>)) {
f(5i32)
}
}
fn produce() -> impl for<T> Trait<(), Assoc = impl Trait<T>> {
//~^ ERROR associated type `Assoc` not found for `Trait`
//~| ERROR associated type `Assoc` not found for `Trait`
//~| the trait bound `{integer}: Trait<()>` is not satisfied
16
}
fn main() {}
Version information
rustc 1.84.0-dev
binary: rustc
commit-hash: unknown
commit-date: unknown
host: x86_64-unknown-linux-gnu
release: 1.84.0-dev
LLVM version: 19.1.1
Command:
/home/gh-matthiaskrgr/.rustup/toolchains/local-debug-assertions/bin/rustc
@rustbot label +F-non_lifetime_binders
Metadata
Metadata
Assignees
Labels
Category: This is a bug.Call for participation: An issue has been fixed and does not reproduce, but no test has been added.`#![feature(non_lifetime_binders)]`Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️Status: A Minimal Complete and Verifiable Example has been found for this issueRelevant to the compiler team, which will review and decide on the PR/issue.This issue requires a build of rustc or tooling with debug-assertions in some way