error: internal compiler error: /rustc-dev/59807616e1fa2540724bfbac14d7976d7e4a3860/compiler/rustc_middle/src/ty/typeck_results.rs:326:13: node_type: no type for node HirId(DefId(0:8 ~ ice_repro[446b]::test_foo).15) (expr `move |input: ParseBuffer|`)
thread 'rustc' (121892) panicked at /rustc-dev/59807616e1fa2540724bfbac14d7976d7e4a3860/compiler/rustc_middle/src/ty/typeck_results.rs:326:13:
Box<dyn Any>
stack backtrace:
0: std::panicking::begin_panic::<rustc_errors::ExplicitBug>
1: <rustc_errors::diagnostic::BugAbort as rustc_errors::diagnostic::EmissionGuarantee>::emit_producing_guarantee
2: rustc_middle::util::bug::opt_span_bug_fmt::<rustc_span::span_encoding::Span>::{closure#0}
3: rustc_middle::ty::context::tls::with_opt::<rustc_middle::util::bug::opt_span_bug_fmt<rustc_span::span_encoding::Span>::{closure#0}, !>::{closure#0}
4: rustc_middle::ty::context::tls::with_context_opt::<rustc_middle::ty::context::tls::with_opt<rustc_middle::util::bug::opt_span_bug_fmt<rustc_span::span_encoding::Span>::{closure#0}, !>::{closure#0}, !>
5: rustc_middle::util::bug::bug_fmt
6: <rustc_middle::ty::typeck_results::TypeckResults>::expr_ty
7: <rustc_hir_typeck::fn_ctxt::FnCtxt>::suggest_deref_or_ref
8: <rustc_hir_typeck::fn_ctxt::FnCtxt>::suggest_deref_ref_or_into
9: <rustc_hir_typeck::fn_ctxt::FnCtxt>::emit_type_mismatch_suggestions
10: <rustc_hir_typeck::fn_ctxt::FnCtxt>::emit_coerce_suggestions
11: <rustc_hir_typeck::fn_ctxt::FnCtxt>::report_arg_errors
12: <rustc_hir_typeck::fn_ctxt::FnCtxt>::check_expr_call
13: <rustc_hir_typeck::fn_ctxt::FnCtxt>::check_expr_with_expectation_and_args
14: <rustc_hir_typeck::fn_ctxt::FnCtxt>::check_expr_call
15: <rustc_hir_typeck::fn_ctxt::FnCtxt>::check_expr_with_expectation_and_args
16: rustc_hir_typeck::check::check_fn
17: <rustc_hir_typeck::fn_ctxt::FnCtxt>::check_expr_closure
18: <rustc_hir_typeck::fn_ctxt::FnCtxt>::check_expr_with_expectation_and_args
19: <rustc_hir_typeck::fn_ctxt::FnCtxt>::check_expr_method_call
20: <rustc_hir_typeck::fn_ctxt::FnCtxt>::check_expr_with_expectation_and_args
21: <rustc_hir_typeck::fn_ctxt::FnCtxt>::check_expr_method_call
22: <rustc_hir_typeck::fn_ctxt::FnCtxt>::check_expr_with_expectation_and_args
23: <rustc_hir_typeck::fn_ctxt::FnCtxt>::check_decl
24: <rustc_hir_typeck::fn_ctxt::FnCtxt>::check_expr_block
25: <rustc_hir_typeck::fn_ctxt::FnCtxt>::check_expr_with_expectation_and_args
26: rustc_hir_typeck::check::check_fn
27: rustc_hir_typeck::typeck_with_inspect::{closure#0}
[... omitted 1 frame ...]
28: <rustc_middle::ty::context::TyCtxt>::par_hir_body_owners::<rustc_hir_analysis::check_crate::{closure#2}>::{closure#0}
29: rustc_hir_analysis::check_crate
30: rustc_interface::passes::analysis
31: rustc_query_impl::execution::try_execute_query::<rustc_middle::query::caches::SingleCache<rustc_middle::query::erase::ErasedData<[u8; 0]>>, true>
32: rustc_interface::interface::run_compiler::<(), rustc_driver_impl::run_compiler::{closure#0}>::{closure#1}
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
note: we would appreciate a bug report: https://github.com/rust-lang/rust/issues/new?labels=C-bug%2C+I-ICE%2C+T-compiler&template=ice.md
note: rustc 1.95.0 (59807616e 2026-04-14) running on x86_64-unknown-linux-gnu
note: compiler flags: --crate-type lib -C embed-bitcode=no -C debuginfo=2 -C incremental=[REDACTED]
note: some of the compiler flags provided by cargo are hidden
query stack during panic:
#0 [typeck] type-checking `test_foo`
#1 [analysis] running analysis passes on crate `ice_repro`
end of query stack
error: could not compile `ice-repro` (lib)
Caused by:
process didn't exit successfully: `/home/tehpers/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/bin/rustc --crate-name ice_repro --edition=2024 src/lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --diagnostic-width=235 --crate-type lib --emit=dep-info,metadata,link -C embed-bitcode=no -C debuginfo=2 --check-cfg 'cfg(docsrs,test)' --check-cfg 'cfg(feature, values())' -C metadata=43381e5be9c10862 -C extra-filename=-d28b6d0dad6ba43b --out-dir /home/tehpers/repos/ice-repro/target/debug/deps -C incremental=/home/tehpers/repos/ice-repro/target/debug/incremental -L dependency=/home/tehpers/repos/ice-repro/target/debug/deps --extern proc_macro2=/home/tehpers/repos/ice-repro/target/debug/deps/libproc_macro2-bd9dcd1cddcb1a55.rmeta --extern syn=/home/tehpers/repos/ice-repro/target/debug/deps/libsyn-ae7472e77795fcfd.rmeta` (exit status: 101)
Code
Meta
rustc --version --verbose:Error output
Backtrace
Cargo.toml
Cargo.lock