Change:
<!-- Thank you for finding an Internal Compiler Error! If possible, try to provide a minimal verifiable example. You can read "Rust Bug Minimization Patterns" for how to create smaller examples. --<!-- If you're using the stable version of the compiler, you should also check if the bug also exists in the beta or nightly versions. --: <!-- Include a backtrace in the code block by setting in your environment. E.g. . --<details<summary<strongBacktrace</strong</summary<p</p</details
Compilation works fine when building WITH .
searched nightlies: from nightly-2023-02-03 to nightly-2023-02-05 regressed nightly: nightly-2023-02-05 searched commit range: regressed commit: () <details<summarybisected with <a href=''cargo-bisect-rustc</av0.6.5</summaryHost triple: x86_64-unknown-linux-gnu Reproduce with: </details
: Building a library and the inline attribute are required to reproduce. This example will also ICE on stable, but if you uncomment the last three lines it only ICEs on nighly. So probably only revealed this bug and isn't the root cause of it. label S-bug-has-mcve
label regression-from-stable-to-nightly
I'm also seeing this. in nightly 2/7/23 This date is a mistake. My bad.
cc either or , this seems to be some weirdness in the handling of trivially false bounds (at least the stable variant, the nightly one might be a different root cause) Edit: Oh, I didn't see that there was a fix up already
This ICE also happens on target x8664-unknown-linux-gnu in , however on target x8664-pc-windows-msvc it did not occur.

Discussion:
// which is different from how types/const are freshened. | TypeFlags::HAS_TY_FRESH.bits | TypeFlags::HAS_CT_FRESH.bits <del> | TypeFlags::HAS_FREE_LOCAL_REGIONS.bits; </del> <ins> | TypeFlags::HAS_FREE_LOCAL_REGIONS.bits | TypeFlags::HAS_RE_ERASED.bits; </ins> /// Does this have `Projection`? const HAS_TY_PROJECTION           = 1 << 10;

<ins> // build-pass #![crate_type = "lib"] pub trait StreamOnce { type Error; } pub trait ResetStream: StreamOnce { fn reset(&mut self) -> Result<(), Self::Error>; } impl<'a> ResetStream for &'a str where Self: StreamOnce { #[inline] fn reset(&mut self) -> Result<(), Self::Error> { Ok(()) } } </ins>

<ins> // build-pass // compile-flags: -C opt-level=3 #![crate_type = "lib"] pub trait Archive { type Archived; type Resolver; fn resolve(resolver: Self::Resolver, out: *mut Self::Archived); } pub type Archived<T> = <T as Archive>::Archived; pub type Resolver<T> = <T as Archive>::Resolver; pub struct Record<'a> { _payload: &'a [u8], } pub struct ArchivedRecord<'a> where &'a [u8]: Archive, { _payload: Archived<&'a [u8]>, } pub struct RecordResolver<'a> where &'a [u8]: Archive, { _payload: Resolver<&'a [u8]>, } impl<'a> Archive for Record<'a> where &'a [u8]: Archive, { type Archived = ArchivedRecord<'a>; type Resolver = RecordResolver<'a>; fn resolve(_resolver: Self::Resolver, _out: *mut Self::Archived) {} } </ins>

= help: a `loop` may express intention better if this is on purpose = note: `#[warn(unconditional_recursion)]` on by default <del> error[E0275]: overflow evaluating the requirement `Map<&mut Map<&mut Map<&mut Map<..., ...>, ...>, ...>, ...>: Iterator` </del> <ins> error[E0275]: overflow evaluating the requirement `Map<&mut std::ops::Range<u8>, [closure@$DIR/issue-83150.rs:12:24: 12:27]>: Iterator` </ins> | = help: consider increasing the recursion limit by adding a `#![recursion_limit = "256"]` attribute to your crate (`issue_83150`) <ins> = note: required for `&mut Map<&mut std::ops::Range<u8>, [closure@$DIR/issue-83150.rs:12:24: 12:27]>` to implement `Iterator` = note: 65 redundant requirements hidden </ins> = note: required for `&mut Map<&mut Map<&mut Map<&mut Map<&mut Map<&mut Map<&mut Map<..., ...>, ...>, ...>, ...>, ...>, ...>, ...>` to implement `Iterator` = note: the full type name has been written to '$TEST_BUILD_DIR/recursion/issue-83150/issue-83150.long-type-hash.txt'