Skip to content

ice: async fn coroutine return type not an inference variable #119890

Closed

Description

@matthiaskrgr

auto-reduced (treereduce-rust):

mod first {
    trait Foo {
        async fn foo<'b>(self: &'b Foo<'a>) -> &() {
            self.0
        }
    }
}

original:

// run-rustfix
#![allow(dead_code)]
mod first {
    trait Foo {
    async fn foo<'b>(self: &'b Foo<'a>) -> &() { self.0 }
}
    fn foo<T: Foo>(a: T) {
        a.m(); //~ ERROR no method named `m` found
    }
}
mod second {
    use std::{
    rc::Rc,
    sync::Arc,
    pin::Pin,
};
    trait Bar { fn m(self: Arc<Self>); }
    fn bar(self: Box<Struct<'a>>, f: &u32) {
        b.m(); //~ ERROR no method named `m` found
    }
}

pub fn main() {
    let x: Box<_> = Box::new(X { a: 32 });
    let new_x = x.change();
    assert_eq!(new_x.a, 55);
}

Version information

rustc 1.77.0-nightly (bfd799f1a 2024-01-12)
binary: rustc
commit-hash: bfd799f1a5a86d16e6b8caa2857bcb4aac6e0174
commit-date: 2024-01-12
host: x86_64-unknown-linux-gnu
release: 1.77.0-nightly
LLVM version: 17.0.6

Command:
/home/matthias/.rustup/toolchains/master/bin/rustc

Program output

error[E0670]: `async fn` is not permitted in Rust 2015
 --> /tmp/icemaker_global_tempdir.PQIGPyZRffct/rustc_testrunner_tmpdir_reporting.a6Tk4AGEOF1i/mvce.rs:3:9
  |
3 |         async fn foo<'b>(self: &'b Foo<'a>) -> &() {
  |         ^^^^^ to use `async fn`, switch to Rust 2018 or later
  |
  = help: pass `--edition 2021` to `rustc`
  = note: for more on editions, read https://doc.rust-lang.org/edition-guide

error[E0261]: use of undeclared lifetime name `'a`
 --> /tmp/icemaker_global_tempdir.PQIGPyZRffct/rustc_testrunner_tmpdir_reporting.a6Tk4AGEOF1i/mvce.rs:3:40
  |
3 |         async fn foo<'b>(self: &'b Foo<'a>) -> &() {
  |                                        ^^ undeclared lifetime
  |
  = note: for more information on higher-ranked polymorphism, visit https://doc.rust-lang.org/nomicon/hrtb.html
help: consider making the bound lifetime-generic with a new `'a` lifetime
  |
3 |         async fn foo<'b>(self: &'b for<'a> Foo<'a>) -> &() {
  |                                    +++++++
help: consider introducing lifetime `'a` here
  |
3 |         async fn foo<'a, 'b>(self: &'b Foo<'a>) -> &() {
  |                      +++
help: consider introducing lifetime `'a` here
  |
2 |     trait Foo<'a> {
  |              ++++

error[E0106]: missing lifetime specifier
 --> /tmp/icemaker_global_tempdir.PQIGPyZRffct/rustc_testrunner_tmpdir_reporting.a6Tk4AGEOF1i/mvce.rs:3:48
  |
3 |         async fn foo<'b>(self: &'b Foo<'a>) -> &() {
  |                                -----------     ^ expected named lifetime parameter
  |
  = help: this function's return type contains a borrowed value with an elided lifetime, but the lifetime cannot be derived from the arguments
help: consider using the `'b` lifetime
  |
3 |         async fn foo<'b>(self: &'b Foo<'a>) -> &'b () {
  |                                                 ++

error[E0601]: `main` function not found in crate `mvce`
 --> /tmp/icemaker_global_tempdir.PQIGPyZRffct/rustc_testrunner_tmpdir_reporting.a6Tk4AGEOF1i/mvce.rs:7:2
  |
7 | }
  |  ^ consider adding a `main` function to `/tmp/icemaker_global_tempdir.PQIGPyZRffct/rustc_testrunner_tmpdir_reporting.a6Tk4AGEOF1i/mvce.rs`

warning: trait objects without an explicit `dyn` are deprecated
 --> /tmp/icemaker_global_tempdir.PQIGPyZRffct/rustc_testrunner_tmpdir_reporting.a6Tk4AGEOF1i/mvce.rs:3:36
  |
3 |         async fn foo<'b>(self: &'b Foo<'a>) -> &() {
  |                                    ^^^^^^^
  |
  = warning: this is accepted in the current edition (Rust 2015) but is a hard error in Rust 2021!
  = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2021/warnings-promoted-to-error.html>
  = note: `#[warn(bare_trait_objects)]` on by default
help: use `dyn`
  |
3 |         async fn foo<'b>(self: &'b dyn Foo<'a>) -> &() {
  |                                    +++

error[E0107]: trait takes 0 lifetime arguments but 1 lifetime argument was supplied
 --> /tmp/icemaker_global_tempdir.PQIGPyZRffct/rustc_testrunner_tmpdir_reporting.a6Tk4AGEOF1i/mvce.rs:3:36
  |
3 |         async fn foo<'b>(self: &'b Foo<'a>) -> &() {
  |                                    ^^^---- help: remove these generics
  |                                    |
  |                                    expected 0 lifetime arguments
  |
note: trait defined here, with 0 lifetime parameters
 --> /tmp/icemaker_global_tempdir.PQIGPyZRffct/rustc_testrunner_tmpdir_reporting.a6Tk4AGEOF1i/mvce.rs:2:11
  |
2 |     trait Foo {
  |           ^^^

error: internal compiler error: compiler/rustc_hir_typeck/src/closure.rs:806:18: async fn coroutine return type not an inference variable: impl Future<Output = &'b ()>
 --> /tmp/icemaker_global_tempdir.PQIGPyZRffct/rustc_testrunner_tmpdir_reporting.a6Tk4AGEOF1i/mvce.rs:3:52
  |
3 |           async fn foo<'b>(self: &'b Foo<'a>) -> &() {
  |  ____________________________________________________^
4 | |             self.0
5 | |         }
  | |_________^

thread 'rustc' panicked at /rustc/bfd799f1a5a86d16e6b8caa2857bcb4aac6e0174/compiler/rustc_errors/src/lib.rs:850:41:
Box<dyn Any>
stack backtrace:
   0:     0x7f1e657af7e6 - std::backtrace_rs::backtrace::libunwind::trace::h1bcd2ce8a0b49e2b
                               at /rustc/bfd799f1a5a86d16e6b8caa2857bcb4aac6e0174/library/std/src/../../backtrace/src/backtrace/libunwind.rs:104:5
   1:     0x7f1e657af7e6 - std::backtrace_rs::backtrace::trace_unsynchronized::hec545b0bca077b29
                               at /rustc/bfd799f1a5a86d16e6b8caa2857bcb4aac6e0174/library/std/src/../../backtrace/src/backtrace/mod.rs:66:5
   2:     0x7f1e657af7e6 - std::sys_common::backtrace::_print_fmt::hb1dc0973745fe00f
                               at /rustc/bfd799f1a5a86d16e6b8caa2857bcb4aac6e0174/library/std/src/sys_common/backtrace.rs:68:5
   3:     0x7f1e657af7e6 - <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt::hc0965f21650fbdf2
                               at /rustc/bfd799f1a5a86d16e6b8caa2857bcb4aac6e0174/library/std/src/sys_common/backtrace.rs:44:22
   4:     0x7f1e65801ec0 - core::fmt::rt::Argument::fmt::h0c3fb88d931991e7
                               at /rustc/bfd799f1a5a86d16e6b8caa2857bcb4aac6e0174/library/core/src/fmt/rt.rs:142:9
   5:     0x7f1e65801ec0 - core::fmt::write::h92f7f8a7341f441f
                               at /rustc/bfd799f1a5a86d16e6b8caa2857bcb4aac6e0174/library/core/src/fmt/mod.rs:1120:17
   6:     0x7f1e657a314f - std::io::Write::write_fmt::h107b5956b3204fe7
                               at /rustc/bfd799f1a5a86d16e6b8caa2857bcb4aac6e0174/library/std/src/io/mod.rs:1810:15
   7:     0x7f1e657af5c4 - std::sys_common::backtrace::_print::haa043cdd6fa0fe1b
                               at /rustc/bfd799f1a5a86d16e6b8caa2857bcb4aac6e0174/library/std/src/sys_common/backtrace.rs:47:5
   8:     0x7f1e657af5c4 - std::sys_common::backtrace::print::h47b083459941ac2d
                               at /rustc/bfd799f1a5a86d16e6b8caa2857bcb4aac6e0174/library/std/src/sys_common/backtrace.rs:34:9
   9:     0x7f1e657b2357 - std::panicking::default_hook::{{closure}}::h474e4c3474397153
  10:     0x7f1e657b20b9 - std::panicking::default_hook::h3bc7fb22936a8edd
                               at /rustc/bfd799f1a5a86d16e6b8caa2857bcb4aac6e0174/library/std/src/panicking.rs:292:9
  11:     0x7f1e62553b0c - std[f8082c656c94fd2d]::panicking::update_hook::<alloc[ef2fed1484295005]::boxed::Box<rustc_driver_impl[24914691d489c447]::install_ice_hook::{closure#0}>>::{closure#0}
  12:     0x7f1e657b2aa6 - <alloc::boxed::Box<F,A> as core::ops::function::Fn<Args>>::call::h98798404485c082c
                               at /rustc/bfd799f1a5a86d16e6b8caa2857bcb4aac6e0174/library/alloc/src/boxed.rs:2030:9
  13:     0x7f1e657b2aa6 - std::panicking::rust_panic_with_hook::hbfa459da89788d0f
                               at /rustc/bfd799f1a5a86d16e6b8caa2857bcb4aac6e0174/library/std/src/panicking.rs:785:13
  14:     0x7f1e62585a34 - std[f8082c656c94fd2d]::panicking::begin_panic::<rustc_errors[70acbb675511353e]::ExplicitBug>::{closure#0}
  15:     0x7f1e62582336 - std[f8082c656c94fd2d]::sys_common::backtrace::__rust_end_short_backtrace::<std[f8082c656c94fd2d]::panicking::begin_panic<rustc_errors[70acbb675511353e]::ExplicitBug>::{closure#0}, !>
  16:     0x7f1e62581fa6 - std[f8082c656c94fd2d]::panicking::begin_panic::<rustc_errors[70acbb675511353e]::ExplicitBug>
  17:     0x7f1e625909e1 - <rustc_errors[70acbb675511353e]::diagnostic_builder::BugAbort as rustc_errors[70acbb675511353e]::diagnostic_builder::EmissionGuarantee>::emit_producing_guarantee
  18:     0x7f1e626db65d - rustc_middle[4be5b913d7bf3685]::util::bug::opt_span_bug_fmt::<rustc_span[e31def1030f5178]::span_encoding::Span>::{closure#0}
  19:     0x7f1e626dbb0a - rustc_middle[4be5b913d7bf3685]::ty::context::tls::with_opt::<rustc_middle[4be5b913d7bf3685]::util::bug::opt_span_bug_fmt<rustc_span[e31def1030f5178]::span_encoding::Span>::{closure#0}, !>::{closure#0}
  20:     0x7f1e626ccd58 - rustc_middle[4be5b913d7bf3685]::ty::context::tls::with_context_opt::<rustc_middle[4be5b913d7bf3685]::ty::context::tls::with_opt<rustc_middle[4be5b913d7bf3685]::util::bug::opt_span_bug_fmt<rustc_span[e31def1030f5178]::span_encoding::Span>::{closure#0}, !>::{closure#0}, !>
  21:     0x7f1e618cc9b4 - rustc_middle[4be5b913d7bf3685]::util::bug::span_bug_fmt::<rustc_span[e31def1030f5178]::span_encoding::Span>
  22:     0x7f1e646ddafa - <rustc_hir_typeck[4037b9c3a0b702b2]::fn_ctxt::FnCtxt>::supplied_sig_of_closure
  23:     0x7f1e63edaa56 - <rustc_hir_typeck[4037b9c3a0b702b2]::fn_ctxt::FnCtxt>::check_expr_closure
  24:     0x7f1e642e0299 - <rustc_hir_typeck[4037b9c3a0b702b2]::fn_ctxt::FnCtxt>::check_expr_with_expectation_and_args
  25:     0x7f1e63e67b08 - rustc_hir_typeck[4037b9c3a0b702b2]::check::check_fn
  26:     0x7f1e63ad21b6 - rustc_hir_typeck[4037b9c3a0b702b2]::typeck
  27:     0x7f1e63ad1535 - rustc_query_impl[5a6eb46947cbd595]::plumbing::__rust_begin_short_backtrace::<rustc_query_impl[5a6eb46947cbd595]::query_impl::typeck::dynamic_query::{closure#2}::{closure#0}, rustc_middle[4be5b913d7bf3685]::query::erase::Erased<[u8; 8usize]>>
  28:     0x7f1e63ceaab9 - rustc_query_system[8201af163ac5a48f]::query::plumbing::try_execute_query::<rustc_query_impl[5a6eb46947cbd595]::DynamicConfig<rustc_query_system[8201af163ac5a48f]::query::caches::VecCache<rustc_span[e31def1030f5178]::def_id::LocalDefId, rustc_middle[4be5b913d7bf3685]::query::erase::Erased<[u8; 8usize]>>, false, false, false>, rustc_query_impl[5a6eb46947cbd595]::plumbing::QueryCtxt, false>
  29:     0x7f1e63cea750 - rustc_query_impl[5a6eb46947cbd595]::query_impl::typeck::get_query_non_incr::__rust_end_short_backtrace
  30:     0x7f1e6481030b - rustc_hir_analysis[a63d9bfdcc7a8c2c]::collect::type_of::type_of_opaque
  31:     0x7f1e6481011b - rustc_query_impl[5a6eb46947cbd595]::plumbing::__rust_begin_short_backtrace::<rustc_query_impl[5a6eb46947cbd595]::query_impl::type_of_opaque::dynamic_query::{closure#2}::{closure#0}, rustc_middle[4be5b913d7bf3685]::query::erase::Erased<[u8; 8usize]>>
  32:     0x7f1e6385f4d4 - rustc_query_system[8201af163ac5a48f]::query::plumbing::try_execute_query::<rustc_query_impl[5a6eb46947cbd595]::DynamicConfig<rustc_query_system[8201af163ac5a48f]::query::caches::DefaultCache<rustc_span[e31def1030f5178]::def_id::DefId, rustc_middle[4be5b913d7bf3685]::query::erase::Erased<[u8; 8usize]>>, false, false, false>, rustc_query_impl[5a6eb46947cbd595]::plumbing::QueryCtxt, false>
  33:     0x7f1e648487a2 - rustc_query_impl[5a6eb46947cbd595]::query_impl::type_of_opaque::get_query_non_incr::__rust_end_short_backtrace
  34:     0x7f1e6385e06e - rustc_middle[4be5b913d7bf3685]::query::plumbing::query_get_at::<rustc_query_system[8201af163ac5a48f]::query::caches::DefaultCache<rustc_span[e31def1030f5178]::def_id::DefId, rustc_middle[4be5b913d7bf3685]::query::erase::Erased<[u8; 8usize]>>>
  35:     0x7f1e61ac6f48 - rustc_hir_analysis[a63d9bfdcc7a8c2c]::collect::type_of::type_of
  36:     0x7f1e63860666 - rustc_query_impl[5a6eb46947cbd595]::plumbing::__rust_begin_short_backtrace::<rustc_query_impl[5a6eb46947cbd595]::query_impl::type_of::dynamic_query::{closure#2}::{closure#0}, rustc_middle[4be5b913d7bf3685]::query::erase::Erased<[u8; 8usize]>>
  37:     0x7f1e6385f4d4 - rustc_query_system[8201af163ac5a48f]::query::plumbing::try_execute_query::<rustc_query_impl[5a6eb46947cbd595]::DynamicConfig<rustc_query_system[8201af163ac5a48f]::query::caches::DefaultCache<rustc_span[e31def1030f5178]::def_id::DefId, rustc_middle[4be5b913d7bf3685]::query::erase::Erased<[u8; 8usize]>>, false, false, false>, rustc_query_impl[5a6eb46947cbd595]::plumbing::QueryCtxt, false>
  38:     0x7f1e6385f09d - rustc_query_impl[5a6eb46947cbd595]::query_impl::type_of::get_query_non_incr::__rust_end_short_backtrace
  39:     0x7f1e6385e06e - rustc_middle[4be5b913d7bf3685]::query::plumbing::query_get_at::<rustc_query_system[8201af163ac5a48f]::query::caches::DefaultCache<rustc_span[e31def1030f5178]::def_id::DefId, rustc_middle[4be5b913d7bf3685]::query::erase::Erased<[u8; 8usize]>>>
  40:     0x7f1e643ac0a9 - rustc_hir_analysis[a63d9bfdcc7a8c2c]::check::check::check_item_type
  41:     0x7f1e63f79cd9 - rustc_hir_analysis[a63d9bfdcc7a8c2c]::check::wfcheck::check_well_formed
  42:     0x7f1e63f78b73 - rustc_query_impl[5a6eb46947cbd595]::plumbing::__rust_begin_short_backtrace::<rustc_query_impl[5a6eb46947cbd595]::query_impl::check_well_formed::dynamic_query::{closure#2}::{closure#0}, rustc_middle[4be5b913d7bf3685]::query::erase::Erased<[u8; 1usize]>>
  43:     0x7f1e63f78271 - rustc_query_system[8201af163ac5a48f]::query::plumbing::try_execute_query::<rustc_query_impl[5a6eb46947cbd595]::DynamicConfig<rustc_query_system[8201af163ac5a48f]::query::caches::VecCache<rustc_hir[fbff31adfa839dea]::hir_id::OwnerId, rustc_middle[4be5b913d7bf3685]::query::erase::Erased<[u8; 1usize]>>, false, false, false>, rustc_query_impl[5a6eb46947cbd595]::plumbing::QueryCtxt, false>
  44:     0x7f1e63f77fdb - rustc_query_impl[5a6eb46947cbd595]::query_impl::check_well_formed::get_query_non_incr::__rust_end_short_backtrace
  45:     0x7f1e63f75977 - rustc_hir_analysis[a63d9bfdcc7a8c2c]::check::wfcheck::check_mod_type_wf
  46:     0x7f1e63f758bb - rustc_query_impl[5a6eb46947cbd595]::plumbing::__rust_begin_short_backtrace::<rustc_query_impl[5a6eb46947cbd595]::query_impl::check_mod_type_wf::dynamic_query::{closure#2}::{closure#0}, rustc_middle[4be5b913d7bf3685]::query::erase::Erased<[u8; 1usize]>>
  47:     0x7f1e63f74a7b - rustc_query_system[8201af163ac5a48f]::query::plumbing::try_execute_query::<rustc_query_impl[5a6eb46947cbd595]::DynamicConfig<rustc_query_system[8201af163ac5a48f]::query::caches::DefaultCache<rustc_span[e31def1030f5178]::def_id::LocalModDefId, rustc_middle[4be5b913d7bf3685]::query::erase::Erased<[u8; 1usize]>>, false, false, false>, rustc_query_impl[5a6eb46947cbd595]::plumbing::QueryCtxt, false>
  48:     0x7f1e63f74813 - rustc_query_impl[5a6eb46947cbd595]::query_impl::check_mod_type_wf::get_query_non_incr::__rust_end_short_backtrace
  49:     0x7f1e63ce7f5a - <rustc_middle[4be5b913d7bf3685]::hir::map::Map>::try_par_for_each_module::<rustc_hir_analysis[a63d9bfdcc7a8c2c]::check_crate::{closure#4}::{closure#0}>::{closure#0}
  50:     0x7f1e63ce8790 - rustc_hir_analysis[a63d9bfdcc7a8c2c]::check_crate
  51:     0x7f1e64419499 - rustc_interface[e8d89524f3b9ea3d]::passes::analysis
  52:     0x7f1e644190df - rustc_query_impl[5a6eb46947cbd595]::plumbing::__rust_begin_short_backtrace::<rustc_query_impl[5a6eb46947cbd595]::query_impl::analysis::dynamic_query::{closure#2}::{closure#0}, rustc_middle[4be5b913d7bf3685]::query::erase::Erased<[u8; 1usize]>>
  53:     0x7f1e647d52e4 - rustc_query_system[8201af163ac5a48f]::query::plumbing::try_execute_query::<rustc_query_impl[5a6eb46947cbd595]::DynamicConfig<rustc_query_system[8201af163ac5a48f]::query::caches::SingleCache<rustc_middle[4be5b913d7bf3685]::query::erase::Erased<[u8; 1usize]>>, false, false, false>, rustc_query_impl[5a6eb46947cbd595]::plumbing::QueryCtxt, false>
  54:     0x7f1e647d50d5 - rustc_query_impl[5a6eb46947cbd595]::query_impl::analysis::get_query_non_incr::__rust_end_short_backtrace
  55:     0x7f1e64542808 - rustc_interface[e8d89524f3b9ea3d]::interface::run_compiler::<core[1ed11a116379b956]::result::Result<(), rustc_span[e31def1030f5178]::ErrorGuaranteed>, rustc_driver_impl[24914691d489c447]::run_compiler::{closure#0}>::{closure#0}
  56:     0x7f1e647ef8c6 - std[f8082c656c94fd2d]::sys_common::backtrace::__rust_begin_short_backtrace::<rustc_interface[e8d89524f3b9ea3d]::util::run_in_thread_with_globals<rustc_interface[e8d89524f3b9ea3d]::util::run_in_thread_pool_with_globals<rustc_interface[e8d89524f3b9ea3d]::interface::run_compiler<core[1ed11a116379b956]::result::Result<(), rustc_span[e31def1030f5178]::ErrorGuaranteed>, rustc_driver_impl[24914691d489c447]::run_compiler::{closure#0}>::{closure#0}, core[1ed11a116379b956]::result::Result<(), rustc_span[e31def1030f5178]::ErrorGuaranteed>>::{closure#0}, core[1ed11a116379b956]::result::Result<(), rustc_span[e31def1030f5178]::ErrorGuaranteed>>::{closure#0}::{closure#0}, core[1ed11a116379b956]::result::Result<(), rustc_span[e31def1030f5178]::ErrorGuaranteed>>
  57:     0x7f1e647ef6f3 - <<std[f8082c656c94fd2d]::thread::Builder>::spawn_unchecked_<rustc_interface[e8d89524f3b9ea3d]::util::run_in_thread_with_globals<rustc_interface[e8d89524f3b9ea3d]::util::run_in_thread_pool_with_globals<rustc_interface[e8d89524f3b9ea3d]::interface::run_compiler<core[1ed11a116379b956]::result::Result<(), rustc_span[e31def1030f5178]::ErrorGuaranteed>, rustc_driver_impl[24914691d489c447]::run_compiler::{closure#0}>::{closure#0}, core[1ed11a116379b956]::result::Result<(), rustc_span[e31def1030f5178]::ErrorGuaranteed>>::{closure#0}, core[1ed11a116379b956]::result::Result<(), rustc_span[e31def1030f5178]::ErrorGuaranteed>>::{closure#0}::{closure#0}, core[1ed11a116379b956]::result::Result<(), rustc_span[e31def1030f5178]::ErrorGuaranteed>>::{closure#1} as core[1ed11a116379b956]::ops::function::FnOnce<()>>::call_once::{shim:vtable#0}
  58:     0x7f1e657bc9d5 - <alloc::boxed::Box<F,A> as core::ops::function::FnOnce<Args>>::call_once::h3db22e8983525486
                               at /rustc/bfd799f1a5a86d16e6b8caa2857bcb4aac6e0174/library/alloc/src/boxed.rs:2016:9
  59:     0x7f1e657bc9d5 - <alloc::boxed::Box<F,A> as core::ops::function::FnOnce<Args>>::call_once::h663b592a11904d0d
                               at /rustc/bfd799f1a5a86d16e6b8caa2857bcb4aac6e0174/library/alloc/src/boxed.rs:2016:9
  60:     0x7f1e657bc9d5 - std::sys::unix::thread::Thread::new::thread_start::h3ab1fb11620916ea
                               at /rustc/bfd799f1a5a86d16e6b8caa2857bcb4aac6e0174/library/std/src/sys/unix/thread.rs:108:17
  61:     0x7f1e5f6749eb - <unknown>
  62:     0x7f1e5f6f87cc - <unknown>
  63:                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.77.0-nightly (bfd799f1a 2024-01-12) running on x86_64-unknown-linux-gnu

query stack during panic:
#0 [typeck] type-checking `first::Foo::foo`
#1 [type_of_opaque] computing type of opaque `first::Foo::foo::{opaque#0}`
#2 [type_of] computing type of `first::Foo::foo::{opaque#0}`
#3 [check_well_formed] checking that `first::Foo::foo::{opaque#0}` is well-formed
#4 [check_mod_type_wf] checking that types are well-formed in module `first`
#5 [analysis] running analysis passes on this crate
end of query stack
error: aborting due to 6 previous errors; 1 warning emitted

Some errors have detailed explanations: E0106, E0107, E0261, E0601, E0670.
For more information about an error, try `rustc --explain E0106`.

Activity

  1. added
    I-ICEIssue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️
    T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.
    C-bugCategory: This is a bug.
    on Jan 12, 2024
  2. added
    needs-triageThis issue may need triage. Remove when done. See docs forge.rust-lang.org/release/issue-triaging
    on Jan 12, 2024
  3. added and removed
    needs-triageThis issue may need triage. Remove when done. See docs forge.rust-lang.org/release/issue-triaging
    on Jan 12, 2024
  4. fmease commented on Jan 12, 2024

    @fmease
    Member

    Also ices in Rust 2021 in case anybody was wondering. Further reduced:

    trait Foo {
        async fn foo<'a>(self: &'a Foo) -> &'a () {
            self.0
        }
    }
  5. added
    S-has-mcveStatus: A Minimal Complete and Verifiable Example has been found for this issue
    on Jan 12, 2024
  6. added
    I-prioritizeIssue needs a team member to assess the impact. Will be replaced by P-{low,medium,high,critical}
    on Jan 12, 2024
  7. added
    E-needs-bisectionCall for participation: This issue needs bisection: https://github.com/rust-lang/cargo-bisect-rustc
    and removed
    I-prioritizeIssue needs a team member to assess the impact. Will be replaced by P-{low,medium,high,critical}
    on Jan 12, 2024
  8. fmease commented on Jan 12, 2024

    @fmease
    Member

    I don't have time to do a bisection but I presume that it regressed in #119148. (see below)

  9. matthiaskrgr commented on Jan 12, 2024

    @matthiaskrgr
    MemberAuthor

    It's #117449 of course 🙃

  10. removed
    E-needs-bisectionCall for participation: This issue needs bisection: https://github.com/rust-lang/cargo-bisect-rustc
    on Jan 12, 2024
  11. matthiaskrgr commented on Jan 16, 2024

    @matthiaskrgr
    MemberAuthor
  12. self-assigned this
    on Jan 16, 2024
  13. added 3 commits that reference this issue on Jan 18, 2024
    5f850f5
    b9235f1
    34362b8
  14. added a commit that references this issue on Jan 18, 2024
    53982cd
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

A-async-awaitArea: Async & AwaitC-bugCategory: This is a bug.I-ICEIssue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️S-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-nightlyPerformance or correctness regression from stable to nightly.

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions