Repository navigation
Closed
Labels
A-macrosArea: All kinds of macros (custom derive, macro_rules!, proc macros, ..)A-proc-macrosArea: Procedural macrosA-resolveArea: Name/path resolution done by `rustc_resolve` specificallyC-bugCategory: This is a bug.I-ICEIssue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️S-has-bisectionStatus: A bisection has been found for this issueS-has-mcveStatus: A Minimal Complete and Verifiable Example has been found for this issueT-compilerRelevant to the compiler team, which will review and decide on the PR/issue.regression-from-stable-to-betaPerformance or correctness regression from stable to beta.
Description
This regression was discovered by the 1.97 beta crater run.
Error output
[INFO] [stdout] note: no errors encountered even though delayed bugs were created
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stderr] 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
[INFO] [stdout] note: those delayed bugs will now be shown as internal compiler errors
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stderr]
[INFO] [stdout] error: internal compiler error: `Res::Err` but no error emitted
[INFO] [stdout] --> src/sync_api.rs:403:5
[INFO] [stdout] |
[INFO] [stdout] 403 | crate::count_tokens( text, model )
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] note: delayed at /rustc-dev/96f70397ed7ba8baf8d1bb541a1ba8e06e3d6f57/compiler/rustc_hir_typeck/src/expr.rs:588:32
[INFO] [stdout] 0: <rustc_errors::DiagCtxtInner>::emit_diagnostic
[INFO] [stdout] 1: <rustc_errors::DiagCtxtHandle>::emit_diagnostic
[INFO] [stdout] 2: <rustc_span::ErrorGuaranteed as rustc_errors::diagnostic::EmissionGuarantee>::emit_producing_guarantee
[INFO] [stdout] 3: <rustc_errors::DiagCtxtHandle>::span_delayed_bug::<rustc_span::span_encoding::Span, &str>
[INFO] [stdout] 4: <rustc_hir_typeck::fn_ctxt::FnCtxt>::check_expr_with_expectation_and_args
[INFO] [stdout] 5: <rustc_hir_typeck::fn_ctxt::FnCtxt>::check_expr_call
[INFO] [stdout] 6: <rustc_hir_typeck::fn_ctxt::FnCtxt>::check_expr_with_expectation_and_args
[INFO] [stdout] 7: <rustc_hir_typeck::fn_ctxt::FnCtxt>::check_expr_block
[INFO] [stdout] 8: <rustc_hir_typeck::fn_ctxt::FnCtxt>::check_expr_with_expectation_and_args
[INFO] [stdout] 9: rustc_hir_typeck::check::check_fn
[INFO] [stdout] 10: rustc_hir_typeck::typeck_with_inspect::{closure#0}
[INFO] [stdout] 11: rustc_query_impl::query_impl::typeck_root::invoke_provider_fn::__rust_begin_short_backtrace
[INFO] [stdout] 12: rustc_query_impl::execution::try_execute_query::<rustc_data_structures::vec_cache::VecCache<rustc_span::def_id::LocalDefId, rustc_middle::query::erase::ErasedData<[u8; 8]>, rustc_middle::dep_graph::graph::DepNodeIndex>, false>
[INFO] [stdout] 13: rustc_query_impl::query_impl::typeck_root::execute_query_non_incr::__rust_end_short_backtrace
[INFO] [stdout] 14: <rustc_middle::ty::context::TyCtxt>::par_hir_body_owners::<rustc_hir_analysis::check_crate::{closure#1}>::{closure#0}
[INFO] [stdout] 15: rustc_hir_analysis::check_crate
[INFO] [stdout] 16: rustc_interface::passes::analysis
[INFO] [stdout] 17: rustc_query_impl::execution::try_execute_query::<rustc_middle::query::caches::SingleCache<rustc_middle::query::erase::ErasedData<[u8; 0]>>, false>
[INFO] [stdout] 18: rustc_query_impl::query_impl::analysis::execute_query_non_incr::__rust_end_short_backtrace
[INFO] [stdout] 19: rustc_interface::interface::run_compiler::<(), rustc_driver_impl::run_compiler::{closure#0}>::{closure#1}
[INFO] [stdout] 20: std::sys::backtrace::__rust_begin_short_backtrace::<rustc_interface::util::run_in_thread_with_globals<rustc_interface::util::run_in_thread_pool_with_globals<rustc_interface::interface::run_compiler<(), rustc_driver_impl::run_compiler::{closure#0}>::{closure#1}, ()>::{closure#0}, ()>::{closure#0}::{closure#0}, ()>
[INFO] [stdout] 21: <std::thread::lifecycle::spawn_unchecked<rustc_interface::util::run_in_thread_with_globals<rustc_interface::util::run_in_thread_pool_with_globals<rustc_interface::interface::run_compiler<(), rustc_driver_impl::run_compiler::{closure#0}>::{closure#1}, ()>::{closure#0}, ()>::{closure#0}::{closure#0}, ()>::{closure#1} as core::ops::function::FnOnce<()>>::call_once::{shim:vtable#0}
[INFO] [stdout] 22: <std::sys::thread::unix::Thread>::new::thread_start
[INFO] [stdout] 23: <unknown>
[INFO] [stdout] 24: clone
[INFO] [stdout]
[INFO] [stdout] --> src/sync_api.rs:403:5
[INFO] [stdout] |
[INFO] [stdout] 403 | crate::count_tokens( text, model )
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stderr] note: rustc 1.97.0-beta.1 (96f70397e 2026-05-26) running on x86_64-unknown-linux-gnu
[INFO] [stdout] error: internal compiler error[E0618]: expected function, found `{type error}`
[INFO] [stdout] --> src/sync_api.rs:403:5
[INFO] [stdout] |
[INFO] [stdout] 403 | crate::count_tokens( text, model )
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^---------------
[INFO] [stdout] | |
[INFO] [stdout] | call expression requires function
[INFO] [stdout] |
[INFO] [stdout] note: delayed at /rustc-dev/96f70397ed7ba8baf8d1bb541a1ba8e06e3d6f57/compiler/rustc_hir_typeck/src/callee.rs:747:34
[INFO] [stdout] 0: <rustc_errors::DiagCtxtInner>::emit_diagnostic
[INFO] [stdout] 1: <rustc_errors::DiagCtxtHandle>::emit_diagnostic
[INFO] [stdout] 2: <rustc_span::ErrorGuaranteed as rustc_errors::diagnostic::EmissionGuarantee>::emit_producing_guarantee
[INFO] [stdout] 3: <rustc_hir_typeck::fn_ctxt::FnCtxt>::check_expr_call
[INFO] [stdout] 4: <rustc_hir_typeck::fn_ctxt::FnCtxt>::check_expr_with_expectation_and_args
[INFO] [stdout] 5: <rustc_hir_typeck::fn_ctxt::FnCtxt>::check_expr_block
[INFO] [stdout] 6: <rustc_hir_typeck::fn_ctxt::FnCtxt>::check_expr_with_expectation_and_args
[INFO] [stdout] 7: rustc_hir_typeck::check::check_fn
[INFO] [stdout] 8: rustc_hir_typeck::typeck_with_inspect::{closure#0}
[INFO] [stdout] 9: rustc_query_impl::query_impl::typeck_root::invoke_provider_fn::__rust_begin_short_backtrace
[INFO] [stdout] 10: rustc_query_impl::execution::try_execute_query::<rustc_data_structures::vec_cache::VecCache<rustc_span::def_id::LocalDefId, rustc_middle::query::erase::ErasedData<[u8; 8]>, rustc_middle::dep_graph::graph::DepNodeIndex>, false>
[INFO] [stdout] 11: rustc_query_impl::query_impl::typeck_root::execute_query_non_incr::__rust_end_short_backtrace
[INFO] [stdout] 12: <rustc_middle::ty::context::TyCtxt>::par_hir_body_owners::<rustc_hir_analysis::check_crate::{closure#1}>::{closure#0}
[INFO] [stdout] 13: rustc_hir_analysis::check_crate
[INFO] [stdout] 14: rustc_interface::passes::analysis
[INFO] [stdout] 15: rustc_query_impl::execution::try_execute_query::<rustc_middle::query::caches::SingleCache<rustc_middle::query::erase::ErasedData<[u8; 0]>>, false>
[INFO] [stdout] 16: rustc_query_impl::query_impl::analysis::execute_query_non_incr::__rust_end_short_backtrace
[INFO] [stdout] 17: rustc_interface::interface::run_compiler::<(), rustc_driver_impl::run_compiler::{closure#0}>::{closure#1}
[INFO] [stdout] 18: std::sys::backtrace::__rust_begin_short_backtrace::<rustc_interface::util::run_in_thread_with_globals<rustc_interface::util::run_in_thread_pool_with_globals<rustc_interface::interface::run_compiler<(), rustc_driver_impl::run_compiler::{closure#0}>::{closure#1}, ()>::{closure#0}, ()>::{closure#0}::{closure#0}, ()>
[INFO] [stdout] 19: <std::thread::lifecycle::spawn_unchecked<rustc_interface::util::run_in_thread_with_globals<rustc_interface::util::run_in_thread_pool_with_globals<rustc_interface::interface::run_compiler<(), rustc_driver_impl::run_compiler::{closure#0}>::{closure#1}, ()>::{closure#0}, ()>::{closure#0}::{closure#0}, ()>::{closure#1} as core::ops::function::FnOnce<()>>::call_once::{shim:vtable#0}
[INFO] [stdout] 20: <std::sys::thread::unix::Thread>::new::thread_start
[INFO] [stdout] 21: <unknown>
[INFO] [stdout] 22: clone
[INFO] [stdout]
[INFO] [stdout] --> src/sync_api.rs:403:5
[INFO] [stdout] |
[INFO] [stdout] 403 | crate::count_tokens( text, model )
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stderr]
[INFO] [stderr] note: compiler flags: --crate-type lib -C embed-bitcode=no -C debuginfo=2
[INFO] [stderr]
[INFO] [stderr] note: some of the compiler flags provided by cargo are hidden
[INFO] [stderr]
[INFO] [stderr] query stack during panic:
[INFO] [stderr] end of query stack
[INFO] [stderr] error: could not compile `api_xai`
https://crater-reports.s3.amazonaws.com/beta-1.97-3-v2/1.97.0-beta.1/reg/api_xai-0.3.0/log.txt
Metadata
Metadata
Assignees
Labels
A-macrosArea: All kinds of macros (custom derive, macro_rules!, proc macros, ..)A-proc-macrosArea: Procedural macrosA-resolveArea: Name/path resolution done by `rustc_resolve` specificallyC-bugCategory: This is a bug.I-ICEIssue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️S-has-bisectionStatus: A bisection has been found for this issueS-has-mcveStatus: A Minimal Complete and Verifiable Example has been found for this issueT-compilerRelevant to the compiler team, which will review and decide on the PR/issue.regression-from-stable-to-betaPerformance or correctness regression from stable to beta.
Activity
theemathas commentedon Jun 4, 2026
Possibly another instance of the same issue in the rustdoc crater run:
https://crater-reports.s3.amazonaws.com/beta-rustdoc-1.97-3/1.97.0-beta.1/reg/willbe-0.35.0/log.txt
theemathas commentedon Jun 5, 2026
what on earth are these two crates (by the same author) doing with their module system...
theemathas commentedon Jun 6, 2026
8 remaining items
theemathas commentedon Jun 6, 2026
Given that the below code doesn't compile, on either stable or beta, maybe the above code shouldn't have compiled in the first place?
petrochenkov commentedon Jun 10, 2026
Fixed in #157719 by reverting a part of #154435.
@theemathas is right, that change uncovered some other issue and the code should likely produce an error, I'll investigate it later when I have time.
Rollup merge of rust-lang#157719 - petrochenkov:regr197err, r=jackh726
Rollup merge of rust-lang#157719 - petrochenkov:regr197err, r=jackh726
Rollup merge of rust-lang#157719 - petrochenkov:regr197err, r=jackh726
Rollup merge of rust-lang#157719 - petrochenkov:regr197err, r=jackh726
Rollup merge of rust-lang#157719 - petrochenkov:regr197err, r=jackh726
Rollup merge of rust-lang#157719 - petrochenkov:regr197err, r=jackh726
theemathas commentedon Jun 11, 2026
Reopening to track beta backport.
Unrolled build for #157719
theemathas commentedon Jun 12, 2026
Fixed by #157787.