[ICE]: just hit internal compiler error
Open
Nobody has claimed this yet.
C-bug
fixed-by-next-solver
I-ICE
needs-triage
T-compiler
- Dominant language
- Rust
- Stars
- 119k
- Forks
- 16.1k
- PR merge metrics
- PR metrics pending
Description
Code
// simulating third-party crate foo
mod foo {
pub trait Protocol {}
#[derive(Default)]
pub struct DefaultProtocol {}
impl Protocol for DefaultProtocol {}
}
pub mod server {
pub mod handler {
use crate::server::service::Service;
pub trait Handler<P, T>: Send + Sync + 'static {
async fn call(&self, protocol: &mut P) -> std::io::Result<()>;
}
pub struct HandlerService<F, T> {
f: F,
_marker: std::marker::PhantomData<fn() -> T>,
}
pub fn handler<P, F, T>(f: F) -> HandlerService<F, T>
where
F: Handler<P, T>,
{
HandlerService {
f,
_marker: std::marker::PhantomData,
}
}
impl<P, F, T> Service<P> for HandlerService<F, T>
where
F: Handler<P, T>,
T: Send + 'static,
P: Send + 'static,
{
async fn call(&self, protocol: &mut P) -> std::io::Result<()> {
self.f.call(protocol).await
}
}
impl<P, F> Handler<P, ()> for F
where
F: AsyncFn(&mut P) -> std::io::Result<()> + Send + Sync + 'static,
P: Send + 'static,
{
async fn call(
&self,
protocol: &mut P,
) -> std::io::Result<()> {
(self)(protocol).await
}
}
}
pub mod router {
use super::handler;
use super::service::{self, Service};
pub struct RouterBuilder<P> {
_phantom: std::marker::PhantomData<P>,
}
impl<P: 'static> RouterBuilder<P> {
pub fn new() -> Self {
Self {
_phantom: std::marker::PhantomData,
}
}
pub fn route<F, T>(&mut self, f: F) -> std::io::Result<()>
where
F: handler::Handler<P, T>,
T: Send + 'static,
P: Send + 'static,
{
self.route_service(handler::handler(f))
}
fn route_service<M>(
&mut self,
service: M,
) -> std::io::Result<()>
where
M: Service<P> + 'static,
{
Self::insert_route(service)
}
fn insert_route<M>(
service: M,
) -> std::io::Result<()>
where
M: Service<P> + 'static,
{
let _ = service::new_box(service);
Ok(())
}
pub fn build(self) -> std::marker::PhantomData<P> {
std::marker::PhantomData
}
}
}
pub mod service {
use std::future::Future;
use std::pin::Pin;
pub trait Service<P>: Send + Sync {
async fn call(&self, session: &mut P) -> std::io::Result<()>;
}
impl<F, P> Service<P> for F
where
F: AsyncFn(&mut P) -> std::io::Result<()> + Send + Sync,
{
async fn call(&self, protocol: &mut P) -> std::io::Result<()> {
self(protocol).await
}
}
pub type BoxFuture<'a, T> = Pin<Box<dyn Future<Output = T> + 'a>>;
pub trait ErasedService<P>: Send + Sync {
fn call<'a>(&'a self, protocol: &'a mut P) -> BoxFuture<'a, std::io::Result<()>>;
}
impl<T, P> ErasedService<P> for T
where
T: Service<P>,
{
fn call<'a>(&'a self, protocol: &'a mut P) -> BoxFuture<'a, std::io::Result<()>> {
Box::pin(Service::call(self, protocol))
}
}
pub type DynService<P> = dyn ErasedService<P>;
pub fn new_box<P, T>(service: T) -> Box<DynService<P>>
where
T: Service<P> + 'static,
P: 'static,
{
Box::new(service)
}
}
pub struct CustomProtocol<'p, P> {
inner: std::marker::PhantomData<(&'p (), P)>,
}
impl<'p, P: crate::foo::Protocol> crate::foo::Protocol for CustomProtocol<'p, P> {}
pub struct Server<P> {
router: std::marker::PhantomData<P>,
}
pub fn init<P: crate::foo::Protocol + Send + 'static>()
-> std::io::Result<Server<CustomProtocol<'static, P>>> {
let server = init_internal()?;
Ok(server)
}
fn init_internal<P>() -> std::io::Result<Server<P>>
where
P: crate::foo::Protocol + Send + 'static,
{
let mut router_builder = router::RouterBuilder::new();
// Closure – does not trigger ICE
let closure_handler_ok = async |_: &mut P| -> std::io::Result<()> {
Ok(())
};
router_builder.route(closure_handler_ok)?;
// Generic async function – this triggers ICE
async fn generic_async_fn_handler_triggers_ice<P: crate::foo::Protocol>(_: &mut P) -> std::io::Result<()> {
Ok(())
}
router_builder.route(generic_async_fn_handler_triggers_ice)?;
Ok(Server {
router: router_builder.build(),
})
}
}
fn main() {
let _server = server::init::<crate::foo::DefaultProtocol>().unwrap();
println!("no ICE");
}
Meta
rustc --version --verbose:
rustc 1.97.1 (8bab26f4f 2026-07-14)
binary: rustc
commit-hash: 8bab26f4f68e0e26f0bb7960be334d5b520ea452
commit-date: 2026-07-14
host: x86_64-unknown-linux-gnu
release: 1.97.1
LLVM version: 22.1.6
Error output
❯ cargo run
Compiling kkkkkkkkkkk v0.1.0 (/tmp/kkkkkkkkkkk)
error: internal compiler error: /rustc-dev/8bab26f4f68e0e26f0bb7960be334d5b520ea452/compiler/rustc_middle/src/ty/instance.rs:566:21: failed to resolve instance for <HandlerService<for<'a> fn(&'a mut CustomProtocol<'_, DefaultProtocol>) -> impl Future<Output = Result<(), std::io::Error>> {generic_async_fn_handler_triggers_ice::<CustomProtocol<'_, DefaultProtocol>>}, ()> as ErasedService<CustomProtocol<'_, DefaultProtocol>>>::call
--> src/main.rs:130:13
|
130 | fn call<'a>(&'a self, protocol: &'a mut P) -> BoxFuture<'a, std::io::Result<()>>;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
thread 'rustc' (1847800) panicked at /rustc-dev/8bab26f4f68e0e26f0bb7960be334d5b520ea452/compiler/rustc_middle/src/ty/instance.rs:566:21:
Box<dyn Any>
stack backtrace:
0: 0x7a5b38a901f9 - <<std[1e3c4ec04c5261a9]::sys::backtrace::BacktraceLock>::print::DisplayBacktrace as core[37f591cfbe66b0b1]::fmt::Display>::fmt
1: 0x7a5b39220cc8 - core[37f591cfbe66b0b1]::fmt::write
2: 0x7a5b3a60d936 - <std[1e3c4ec04c5261a9]::sys::stdio::unix::Stderr as std[1e3c4ec04c5261a9]::io::Write>::write_fmt
3: 0x7a5b38a663fe - std[1e3c4ec04c5261a9]::panicking::default_hook::{closure#0}
4: 0x7a5b38a83b33 - std[1e3c4ec04c5261a9]::panicking::default_hook
5: 0x7a5b37876c31 - std[1e3c4ec04c5261a9]::panicking::update_hook::<alloc[24b8200b0946867]::boxed::Box<rustc_driver_impl[4e5b0da0f4005eeb]::install_ice_hook::{closure#1}>>::{closure#0}
6: 0x7a5b38a83e12 - std[1e3c4ec04c5261a9]::panicking::panic_with_hook
7: 0x7a5b378a4c81 - std[1e3c4ec04c5261a9]::panicking::begin_panic::<rustc_errors[7f21b2e3bec875a6]::ExplicitBug>::{closure#0}
8: 0x7a5b3789d9f6 - std[1e3c4ec04c5261a9]::sys::backtrace::__rust_end_short_backtrace::<std[1e3c4ec04c5261a9]::panicking::begin_panic<rustc_errors[7f21b2e3bec875a6]::ExplicitBug>::{closure#0}, !>
9: 0x7a5b3789ba28 - std[1e3c4ec04c5261a9]::panicking::begin_panic::<rustc_errors[7f21b2e3bec875a6]::ExplicitBug>
10: 0x7a5b378b02a1 - <rustc_errors[7f21b2e3bec875a6]::diagnostic::BugAbort as rustc_errors[7f21b2e3bec875a6]::diagnostic::EmissionGuarantee>::emit_producing_guarantee
11: 0x7a5b37f19ddc - <rustc_errors[7f21b2e3bec875a6]::DiagCtxtHandle>::span_bug::<rustc_span[d86c6dd34b0962f8]::span_encoding::Span, alloc[24b8200b0946867]::string::String>
12: 0x7a5b37f45986 - rustc_middle[8a940fbd8c5d50e6]::util::bug::opt_span_bug_fmt::<rustc_span[d86c6dd34b0962f8]::span_encoding::Span>::{closure#0}
13: 0x7a5b37f45b12 - rustc_middle[8a940fbd8c5d50e6]::ty::context::tls::with_opt::<rustc_middle[8a940fbd8c5d50e6]::util::bug::opt_span_bug_fmt<rustc_span[d86c6dd34b0962f8]::span_encoding::Span>::{closure#0}, !>::{closure#0}
14: 0x7a5b37f345bb - rustc_middle[8a940fbd8c5d50e6]::ty::context::tls::with_context_opt::<rustc_middle[8a940fbd8c5d50e6]::ty::context::tls::with_opt<rustc_middle[8a940fbd8c5d50e6]::util::bug::opt_span_bug_fmt<rustc_span[d86c6dd34b0962f8]::span_encoding::Span>::{closure#0}, !>::{closure#0}, !>
15: 0x7a5b35dbcdf8 - rustc_middle[8a940fbd8c5d50e6]::util::bug::span_bug_fmt::<rustc_span[d86c6dd34b0962f8]::span_encoding::Span>
16: 0x7a5b3a0d0621 - <rustc_middle[8a940fbd8c5d50e6]::ty::instance::Instance>::expect_resolve
17: 0x7a5b3a0cf5ff - <rustc_middle[8a940fbd8c5d50e6]::ty::instance::Instance>::expect_resolve_for_vtable
18: 0x7a5b3a0ceaae - rustc_trait_selection[c5d69b98270b4c69]::traits::vtable::vtable_entries::{closure#0}
19: 0x7a5b3a0cbfa0 - rustc_trait_selection[c5d69b98270b4c69]::traits::vtable::vtable_entries
20: 0x7a5b3a0cb953 - rustc_query_impl[bdb42d22f02e134a]::query_impl::vtable_entries::invoke_provider_fn::__rust_begin_short_backtrace
21: 0x7a5b3a0c85e7 - rustc_query_impl[bdb42d22f02e134a]::execution::try_execute_query::<rustc_middle[8a940fbd8c5d50e6]::query::caches::DefaultCache<rustc_type_ir[f110db280fa5959f]::predicate::TraitRef<rustc_middle[8a940fbd8c5d50e6]::ty::context::TyCtxt>, rustc_middle[8a940fbd8c5d50e6]::query::erase::ErasedData<[u8; 16usize]>>, true>
22: 0x7a5b3a0c8119 - rustc_query_impl[bdb42d22f02e134a]::query_impl::vtable_entries::execute_query_incr::__rust_end_short_backtrace
23: 0x7a5b39c65fd0 - rustc_monomorphize[c0b603f06e683ae4]::collector::create_mono_items_for_vtable_methods
24: 0x7a5b39c90bcc - rustc_monomorphize[c0b603f06e683ae4]::collector::items_of_instance
25: 0x7a5b39c8d3d1 - rustc_query_impl[bdb42d22f02e134a]::query_impl::items_of_instance::invoke_provider_fn::__rust_begin_short_backtrace
26: 0x7a5b39470c46 - rustc_query_impl[bdb42d22f02e134a]::execution::try_execute_query::<rustc_middle[8a940fbd8c5d50e6]::query::caches::DefaultCache<(rustc_middle[8a940fbd8c5d50e6]::ty::instance::Instance, rustc_middle[8a940fbd8c5d50e6]::mono::CollectionMode), rustc_middle[8a940fbd8c5d50e6]::query::erase::ErasedData<[u8; 32usize]>>, true>
27: 0x7a5b3946f5e6 - rustc_query_impl[bdb42d22f02e134a]::query_impl::items_of_instance::execute_query_incr::__rust_end_short_backtrace
28: 0x7a5b3a17eaea - rustc_monomorphize[c0b603f06e683ae4]::collector::collect_items_rec
29: 0x7a5b3a180921 - rustc_monomorphize[c0b603f06e683ae4]::collector::collect_items_rec
30: 0x7a5b3a180921 - rustc_monomorphize[c0b603f06e683ae4]::collector::collect_items_rec
31: 0x7a5b3a180921 - rustc_monomorphize[c0b603f06e683ae4]::collector::collect_items_rec
32: 0x7a5b3a180921 - rustc_monomorphize[c0b603f06e683ae4]::collector::collect_items_rec
33: 0x7a5b3a180921 - rustc_monomorphize[c0b603f06e683ae4]::collector::collect_items_rec
34: 0x7a5b3a180921 - rustc_monomorphize[c0b603f06e683ae4]::collector::collect_items_rec
35: 0x7a5b3a17657f - rustc_monomorphize[c0b603f06e683ae4]::collector::collect_crate_mono_items::{closure#1}::{closure#0}
36: 0x7a5b3a177237 - rustc_monomorphize[c0b603f06e683ae4]::partitioning::collect_and_partition_mono_items
37: 0x7a5b3a176eea - rustc_query_impl[bdb42d22f02e134a]::query_impl::collect_and_partition_mono_items::invoke_provider_fn::__rust_begin_short_backtrace
38: 0x7a5b3a846356 - rustc_query_impl[bdb42d22f02e134a]::execution::try_execute_query::<rustc_middle[8a940fbd8c5d50e6]::query::caches::SingleCache<rustc_middle[8a940fbd8c5d50e6]::query::erase::ErasedData<[u8; 24usize]>>, true>
39: 0x7a5b3a845e94 - rustc_query_impl[bdb42d22f02e134a]::query_impl::collect_and_partition_mono_items::execute_query_incr::__rust_end_short_backtrace
40: 0x7a5b3a434972 - rustc_codegen_ssa[20a34f9232644acf]::base::codegen_crate::<rustc_codegen_llvm[49149b7e7b12cc7]::LlvmCodegenBackend>
41: 0x7a5b3a43468d - <rustc_codegen_llvm[49149b7e7b12cc7]::LlvmCodegenBackend as rustc_codegen_ssa[20a34f9232644acf]::traits::backend::CodegenBackend>::codegen_crate
42: 0x7a5b3a32c95c - <rustc_interface[6818d3a8678689ee]::queries::Linker>::codegen_and_build_linker
43: 0x7a5b3a326fcb - rustc_interface[6818d3a8678689ee]::interface::run_compiler::<(), rustc_driver_impl[4e5b0da0f4005eeb]::run_compiler::{closure#0}>::{closure#1}
44: 0x7a5b3a35407a - std[1e3c4ec04c5261a9]::sys::backtrace::__rust_begin_short_backtrace::<rustc_interface[6818d3a8678689ee]::util::run_in_thread_with_globals<rustc_interface[6818d3a8678689ee]::util::run_in_thread_pool_with_globals<rustc_interface[6818d3a8678689ee]::interface::run_compiler<(), rustc_driver_impl[4e5b0da0f4005eeb]::run_compiler::{closure#0}>::{closure#1}, ()>::{closure#0}, ()>::{closure#0}::{closure#0}, ()>
45: 0x7a5b3a35476d - <std[1e3c4ec04c5261a9]::thread::lifecycle::spawn_unchecked<rustc_interface[6818d3a8678689ee]::util::run_in_thread_with_globals<rustc_interface[6818d3a8678689ee]::util::run_in_thread_pool_with_globals<rustc_interface[6818d3a8678689ee]::interface::run_compiler<(), rustc_driver_impl[4e5b0da0f4005eeb]::run_compiler::{closure#0}>::{closure#1}, ()>::{closure#0}, ()>::{closure#0}::{closure#0}, ()>::{closure#1} as core[37f591cfbe66b0b1]::ops::function::FnOnce<()>>::call_once::{shim:vtable#0}
46: 0x7a5b3a35556c - <std[1e3c4ec04c5261a9]::sys::thread::unix::Thread>::new::thread_start
47: 0x7a5b3389cb84 - start_thread
at ./nptl/pthread_create.c:447:8
48: 0x7a5b33929d6c - clone3
at ./misc/../sysdeps/unix/sysv/linux/x86_64/clone3.S:78:0
49: 0x0 - <unknown>
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.97.1 (8bab26f4f 2026-07-14) running on x86_64-unknown-linux-gnu
note: compiler flags: --crate-type bin -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 [vtable_entries] finding all vtable entries for trait `server::service::ErasedService`
#1 [items_of_instance] collecting items used by `server::service::new_box::<server::CustomProtocol<'_, foo::DefaultProtocol>, server::handler::HandlerService<server::init_internal::generic_async_fn_handler_triggers_ice<server::CustomProtocol<'_, foo::DefaultProtocol>>, ()>>`
... and 1 other queries... use `env RUST_BACKTRACE=1` to see the full query stack
warning: `kkkkkkkkkkk` (bin "kkkkkkkkkkk") generated 2 warnings
error: could not compile `kkkkkkkkkkk` (bin "kkkkkkkkkkk"); 2 warnings emitted
Caused by:
process didn't exit successfully: `/home/<user>/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/bin/rustc --crate-name kkkkkkkkkkk --edition=2024 src/main.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --diagnostic-width=239 --crate-type bin --emit=dep-info,link -C embed-bitcode=no -C debuginfo=2 --check-cfg 'cfg(docsrs,test)' --check-cfg 'cfg(feature, values())' -C metadata=11949ff5252d7463 -C extra-filename=-1b5d4bd723661f69 --out-dir /tmp/kkkkkkkkkkk/target/debug/deps -C incremental=/tmp/kkkkkkkkkkk/target/debug/incremental -L dependency=/tmp/kkkkkkkkkkk/target/debug/deps` (exit status: 101)
Backtrace
❯ RUST_BACKTRACE=1 cargo build
Compiling kkkkkkkkkkk v0.1.0 (/tmp/kkkkkkkkkkk)
error: internal compiler error: /rustc-dev/8bab26f4f68e0e26f0bb7960be334d5b520ea452/compiler/rustc_middle/src/ty/instance.rs:566:21: failed to resolve instance for <HandlerService<for<'a> fn(&'a mut CustomProtocol<'_, DefaultProtocol>) -> impl Future<Output = Result<(), std::io::Error>> {generic_async_fn_handler_triggers_ice::<CustomProtocol<'_, DefaultProtocol>>}, ()> as ErasedService<CustomProtocol<'_, DefaultProtocol>>>::call
--> src/main.rs:130:13
|
130 | fn call<'a>(&'a self, protocol: &'a mut P) -> BoxFuture<'a, std::io::Result<()>>;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
thread 'rustc' (1851606) panicked at /rustc-dev/8bab26f4f68e0e26f0bb7960be334d5b520ea452/compiler/rustc_middle/src/ty/instance.rs:566:21:
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_errors::DiagCtxtHandle>::span_bug::<rustc_span::span_encoding::Span, alloc::string::String>
3: rustc_middle::util::bug::opt_span_bug_fmt::<rustc_span::span_encoding::Span>::{closure#0}
4: 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::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}, !>
6: rustc_middle::util::bug::span_bug_fmt::<rustc_span::span_encoding::Span>
7: <rustc_middle::ty::instance::Instance>::expect_resolve
8: <rustc_middle::ty::instance::Instance>::expect_resolve_for_vtable
9: rustc_trait_selection::traits::vtable::vtable_entries::{closure#0}
10: rustc_trait_selection::traits::vtable::vtable_entries
[... omitted 1 frame ...]
11: rustc_monomorphize::collector::create_mono_items_for_vtable_methods
12: rustc_monomorphize::collector::items_of_instance
[... omitted 1 frame ...]
13: rustc_monomorphize::collector::collect_items_rec
14: rustc_monomorphize::collector::collect_items_rec
15: rustc_monomorphize::collector::collect_items_rec
16: rustc_monomorphize::collector::collect_items_rec
17: rustc_monomorphize::collector::collect_items_rec
18: rustc_monomorphize::collector::collect_items_rec
19: rustc_monomorphize::collector::collect_items_rec
20: rustc_monomorphize::collector::collect_crate_mono_items::{closure#1}::{closure#0}
21: rustc_monomorphize::partitioning::collect_and_partition_mono_items
[... omitted 1 frame ...]
22: rustc_codegen_ssa::base::codegen_crate::<rustc_codegen_llvm::LlvmCodegenBackend>
23: <rustc_codegen_llvm::LlvmCodegenBackend as rustc_codegen_ssa::traits::backend::CodegenBackend>::codegen_crate
24: <rustc_interface::queries::Linker>::codegen_and_build_linker
25: 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.97.1 (8bab26f4f 2026-07-14) running on x86_64-unknown-linux-gnu
note: compiler flags: --crate-type bin -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 [vtable_entries] finding all vtable entries for trait `server::service::ErasedService`
#1 [items_of_instance] collecting items used by `server::service::new_box::<server::CustomProtocol<'_, foo::DefaultProtocol>, server::handler::HandlerService<server::init_internal::generic_async_fn_handler_triggers_ice<server::CustomProtocol<'_, foo::DefaultProtocol>>, ()>>`
#2 [collect_and_partition_mono_items] collect_and_partition_mono_items
end of query stack
warning: `kkkkkkkkkkk` (bin "kkkkkkkkkkk") generated 2 warnings
error: could not compile `kkkkkkkkkkk` (bin "kkkkkkkkkkk"); 2 warnings emitted
Caused by:
process didn't exit successfully: `/home/<user>/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/bin/rustc --crate-name kkkkkkkkkkk --edition=2024 src/main.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --diagnostic-width=239 --crate-type bin --emit=dep-info,link -C embed-bitcode=no -C debuginfo=2 --check-cfg 'cfg(docsrs,test)' --check-cfg 'cfg(feature, values())' -C metadata=11949ff5252d7463 -C extra-filename=-1b5d4bd723661f69 --out-dir /tmp/kkkkkkkkkkk/target/debug/deps -C incremental=/tmp/kkkkkkkkkkk/target/debug/incremental -L dependency=/tmp/kkkkkkkkkkk/target/debug/deps` (exit status: 101)
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the ICE with the self-contained src/main.rs example using cargo run. Start at rustc_middle/src/ty/instance.rs:566 and follow the vtable path through rustc_trait_selection traits::vtable and rustc_monomorphize's collector; done means this generic async-function case no longer causes an internal compiler error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- compilers
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100