Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

regression: unwrap on None in ast lowering #123287

Closed
Mark-Simulacrum opened this issue Mar 31, 2024 · 5 comments
Closed

regression: unwrap on None in ast lowering #123287

Mark-Simulacrum opened this issue Mar 31, 2024 · 5 comments
Assignees
Labels
I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️ P-critical Critical priority regression-from-stable-to-beta Performance or correctness regression from stable to beta. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Milestone

Comments

@Mark-Simulacrum
Copy link
Member

Mark-Simulacrum commented Mar 31, 2024

[INFO] [stderr] thread 'rustc' panicked at compiler/rustc_ast_lowering/src/lib.rs:946:56:
[INFO] [stderr] called `Option::unwrap()` on a `None` value
[...]
[INFO] [stderr]   20:     0x7f80622076bd - <rustc_ast_lowering[c375b381c4432908]::LoweringContext>::lower_attrs
[INFO] [stderr]   21:     0x7f806220fadb - <rustc_ast_lowering[c375b381c4432908]::LoweringContext>::lower_assoc_item
[INFO] [stderr]   22:     0x7f806220a1e1 - <rustc_ast_lowering[c375b381c4432908]::item::ItemLowerer>::lower_node
[INFO] [stderr]   23:     0x7f806220c879 - rustc_ast_lowering[c375b381c4432908]::lower_to_hir
[INFO] [stderr]   24:     0x7f806286e1a0 - rustc_query_impl[ad8bed1ffb21e22c]::plumbing::__rust_begin_short_backtrace::<rustc_query_impl[ad8bed1ffb21e22c]::query_impl::hir_crate::dynamic_query::{closure#2}::{closure#0}, rustc_middle[16e6156279eb1caf]::query::erase::Erased<[u8; 8usize]>>
[INFO] [stderr]   25:     0x7f8062883b6a - rustc_query_system[4beaed5e390715c6]::query::plumbing::try_execute_query::<rustc_query_impl[ad8bed1ffb21e22c]::DynamicConfig<rustc_query_system[4beaed5e390715c6]::query::caches::SingleCache<rustc_middle[16e6156279eb1caf]::query::erase::Erased<[u8; 8usize]>>, false, false, false>, rustc_query_impl[ad8bed1ffb21e22c]::plumbing::QueryCtxt, false>
[INFO] [stderr]   26:     0x7f8062883782 - rustc_query_impl[ad8bed1ffb21e22c]::query_impl::hir_crate::get_query_non_incr::__rust_end_short_backtrace
[INFO] [stderr]   27:     0x7f8062cda018 - rustc_query_impl[ad8bed1ffb21e22c]::plumbing::__rust_begin_short_backtrace::<rustc_query_impl[ad8bed1ffb21e22c]::query_impl::opt_hir_owner_nodes::dynamic_query::{closure#2}::{closure#0}, rustc_middle[16e6156279eb1caf]::query::erase::Erased<[u8; 8usize]>>.warm
[INFO] [stderr]   28:     0x7f8061d9a02d - rustc_query_system[4beaed5e390715c6]::query::plumbing::try_execute_query::<rustc_query_impl[ad8bed1ffb21e22c]::DynamicConfig<rustc_query_system[4beaed5e390715c6]::query::caches::VecCache<rustc_span[5f5e31a6435c6e19]::def_id::LocalDefId, rustc_middle[16e6156279eb1caf]::query::erase::Erased<[u8; 8usize]>>, false, false, false>, rustc_query_impl[ad8bed1ffb21e22c]::plumbing::QueryCtxt, false>
[INFO] [stderr]   29:     0x7f8061d99d09 - rustc_query_impl[ad8bed1ffb21e22c]::query_impl::opt_hir_owner_nodes::get_query_non_incr::__rust_end_short_backtrace
[INFO] [stderr]   30:     0x7f8061e69898 - <rustc_middle[16e6156279eb1caf]::ty::context::TyCtxt>::expect_hir_owner_nodes
[INFO] [stderr]   31:     0x7f8061e649a0 - rustc_middle[16e6156279eb1caf]::hir::map::hir_crate_items

(and other cases too)

@Mark-Simulacrum Mark-Simulacrum added I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️ T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. regression-from-stable-to-beta Performance or correctness regression from stable to beta. labels Mar 31, 2024
@Mark-Simulacrum Mark-Simulacrum added this to the 1.78.0 milestone Mar 31, 2024
@rustbot rustbot added I-prioritize Issue: Indicates that prioritization has been requested for this issue. needs-triage This issue may need triage. Remove it if it has been sufficiently triaged. labels Mar 31, 2024
@matthiaskrgr
Copy link
Member

might be related to #121537

@compiler-errors
Copy link
Member

The PR introducing the regression in this rollup is #121120: Add ErrorGuaranteed to ast::LitKind::Err, `token::LitKi…

searched nightlies: from nightly-2024-01-01 to nightly-2024-03-16
regressed nightly: nightly-2024-02-16
searched commit range: ee9c7c9...a447249
regressed commit: cbddf31

bisected with cargo-bisect-rustc v0.6.8

Host triple: x86_64-unknown-linux-gnu
Reproduce with:

cargo bisect-rustc --start=2024-01-01 --end=2024-03-16 -- build 

cc @nnethercote

Maybe check that #121545 fixes this (#121537 (comment)) and we just need to backport that?

@Noratrieb Noratrieb removed the needs-triage This issue may need triage. Remove it if it has been sufficiently triaged. label Mar 31, 2024
@apiraino
Copy link
Contributor

apiraino commented Apr 2, 2024

WG-prioritization assigning priority (Zulip discussion).

@rustbot label -I-prioritize +P-critical

@rustbot rustbot added P-critical Critical priority and removed I-prioritize Issue: Indicates that prioritization has been requested for this issue. labels Apr 2, 2024
@pnkfelix pnkfelix self-assigned this Apr 4, 2024
@wesleywiser
Copy link
Member

@pnkfelix confirms this will be fixed by the backport of #121545

@cuviper
Copy link
Member

cuviper commented Apr 12, 2024

Backported in #123801.

@cuviper cuviper closed this as completed Apr 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️ P-critical Critical priority regression-from-stable-to-beta Performance or correctness regression from stable to beta. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

No branches or pull requests

9 participants