Change:
let Some(module) = single_import.imported_module.get() else { return Err((Undetermined, Weak::No)); }; <del> let ImportKind::Single { source: ident, target, target_bindings, .. } = &single_import.kind </del> <ins> let ImportKind::Single { source, target, target_bindings, .. } = &single_import.kind </ins> else { unreachable!(); }; <del> if (ident != target) && target_bindings.iter().all(|binding| binding.get().is_none()) { </del> <ins> if source != target { </ins> // This branch allows the binding to be defined or updated later if the target name <del> // can hide the source but these bindings are not obtained. // avoiding module inconsistency between the resolve process and the finalize process. // See more details in #124840 return Err((Undetermined, Weak::No)); </del> <ins> // can hide the source. if target_bindings.iter().all(|binding| binding.get().is_none()) { // None of the target bindings are available, so we can't determine // if this binding is correct or not. // See more details in #124840 return Err((Undetermined, Weak::No)); } else if target_bindings[ns].get().is_none() && binding.is_some() { // `binding.is_some()` avoids the condition where the binding // truly doesn't exist in this namespace and should return `Err(Determined)`. return Err((Undetermined, Weak::No)); } </ins> } match self.resolve_ident_in_module( module, <del> *ident, </del> <ins> *source, </ins> ns, &single_import.parent_scope, None,

Discussion:
<!-- [31mICE[0m: Rustc '' 'error: internal compiler error: inconsistent resolution for an import', 'error: internal compiler error: inconsistent resolution for an import' File: --auto-reduced (treereduce-rust): original: Version information ` Command: <!-- Include a backtrace in the code block by setting in your environment. E.g. . --<details<summary<strongProgram output</strong</summary<p</p</details<!-- query stack: [resolverforlowering_raw] getting the resolver for lowering --
Isn't this example identical to EDIT: oh I see, the PR that closes doesn't actually have this test, so it's possible this is a different ICE.
This one has an additional which indeed causes the ICE to trigger again :laughing:
Regression in nightly-2020-11-09 commit[0] 2020-11-07: Auto merge of - Mark-Simulacrum:debug-asserts, r=pietroalbini commit[1] 2020-11-07: Auto merge of - Mark-Simulacrum:revert-, r=petrochenkov commit[2] 2020-11-08: Auto merge of - petrochenkov:mergetarg, r=Mark-Simulacrum commit[3] 2020-11-08: Auto merge of - lcnr:revert75443, r=nikomatsakis commit[4] 2020-11-08: Auto merge of - m-ou-se:rollup-3jp1ijj, r=m-ou-se commit[5] 2020-11-08: Auto merge of - petrochenkov:visitok, r=Aaron1011

<!-- [31mICE[0m: Rustc '' 'thread 'rustc' panicked at 'assertion failed: ().isnone()'', 'thread 'rustc' panicked at 'assertion failed: ().isnone()'' File: --auto-reduced (treereduce-rust): original: Version information ` Command: <!-- Include a backtrace in the code block by setting in your environment. E.g. . --<details<summary<strongProgram output</strong</summary<p</p</details<!-- query stack: [resolverforloweringraw] getting the resolver for lowering --<!-- TRIAGEBOTSTART --<!-- TRIAGEBOTASSIGNSTART --<!-- TRIAGEBOTASSIGNDATASTARTTRIAGEBOTASSIGNDATAEND --<!-- TRIAGEBOTASSIGNEND --<!-- TRIAGEBOT_END --
cc as this looks 99% like and you fixed that one recently ^^
claim. I will investigate it in my spare time.