Repository navigation
ICE: error from fully_perform, with HRTB on GAT #136666
Copy link
Copy link
Closed as duplicate
Labels
C-bugCategory: This is a bug.Category: This is a bug.I-ICEIssue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️S-bug-has-testStatus: This bug is tracked inside the repo by a `known-bug` test.Status: This bug is tracked inside the repo by a `known-bug` test.T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.Relevant to the compiler team, which will review and decide on the PR/issue.T-typesRelevant to the types team, which will review and decide on the PR/issue.Relevant to the types team, which will review and decide on the PR/issue.
Description
Activity
- addedC-bugCategory: This is a bug.Category: This is a bug.I-ICEIssue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.Relevant to the compiler team, which will review and decide on the PR/issue.
on Feb 6, 2025 - addedneeds-triageThis issue may need triage. Remove when done. See docs forge.rust-lang.org/release/issue-triagingThis issue may need triage. Remove when done. See docs forge.rust-lang.org/release/issue-triaging
on Feb 6, 2025 - addedT-typesRelevant to the types team, which will review and decide on the PR/issue.Relevant to the types team, which will review and decide on the PR/issue.and removedneeds-triageThis issue may need triage. Remove when done. See docs forge.rust-lang.org/release/issue-triagingThis issue may need triage. Remove when done. See docs forge.rust-lang.org/release/issue-triaging
on Feb 6, 2025 Slightly simplified and reorganized:
// Needed so that rust can infer that the A in what() is &() trait IsRef<T> {} struct Dummy; impl<'a> IsRef<&'a ()> for Dummy {} trait WithLifetime { type Output<'a>; } impl<'t> WithLifetime for &'t () { type Output<'a> = &'a (); } // Needed to prevent the two Foo impls from overlapping struct Wrap<A>(A); trait Unimplemented {} trait Foo {} impl<T> Foo for T where T: Unimplemented {} impl<A> Foo for Wrap<A> where Dummy: IsRef<A>, for<'a> A: WithLifetime<Output<'a> = A>, { } fn what<A>() where Wrap<A>: Foo, { } fn main() { what(); }
- addedS-bug-has-testStatus: This bug is tracked inside the repo by a `known-bug` test.Status: This bug is tracked inside the repo by a `known-bug` test.
on Mar 9, 2025 duplicate of #124440. Will be fixed by next-solver
- added a commit that references this issue
on Oct 8, 2026
Metadata
Metadata
Assignees
Labels
C-bugCategory: This is a bug.Category: This is a bug.I-ICEIssue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️S-bug-has-testStatus: This bug is tracked inside the repo by a `known-bug` test.Status: This bug is tracked inside the repo by a `known-bug` test.T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.Relevant to the compiler team, which will review and decide on the PR/issue.T-typesRelevant to the types team, which will review and decide on the PR/issue.Relevant to the types team, which will review and decide on the PR/issue.
Code
Minimal example below, with rust playground link. This may be related to #130797, as both involve type inference when there is a HRTB over a GAT, though that bug specifically involves usage with trait objects, where this bug did not occur when using trait objects.
Meta
rustc --version --verbose:Also tested on stable channel, with the same behavior.
Error output
Backtrace