Skip to content

diagnostic_namespace was not listed in declare_features ICE #122446

Closed
@CraZySacX

Description

@CraZySacX

Summary

When compiling my unstable feature and diagnostic_namespace is included I got the attached ICE.

The following is the unstable configuration

#![cfg_attr(
    all(feature = "unstable", nightly),
    feature(
        diagnostic_namespace,
        lint_reasons,
        multiple_supertrait_upcastable,
        must_not_suspend,
        non_exhaustive_omitted_patterns_lint,
        rustdoc_missing_doc_code_examples,
        strict_provenance,
        type_privacy_lints,
    )
)]

https://github.com/rustyhorde/pud is the repository this occurs on. I will get a minimal verifiable example setup shortly.

Version

rustc 1.78.0-nightly (a165f1f65 2024-03-12)
binary: rustc
commit-hash: a165f1f65015b1bd4afd2ec50700aaacf2e0c485
commit-date: 2024-03-12
host: x86_64-unknown-linux-gnu
release: 1.78.0-nightly
LLVM version: 18.1.0

Error output

Backtrace

thread 'rustc' panicked at compiler/rustc_feature/src/unstable.rs:172:1:
`diagnostic_namespace` was not listed in `declare_features`
stack backtrace:
 0:     0x71d0020346cf - std::backtrace_rs::backtrace::libunwind::trace::h62f3b47628dd17b6
                             at /rustc/a165f1f65015b1bd4afd2ec50700aaacf2e0c485/library/std/src/../../backtrace/src/backtrace/libunwind.rs:105:5
 1:     0x71d0020346cf - std::backtrace_rs::backtrace::trace_unsynchronized::hf69f72db4a833c5a
                             at /rustc/a165f1f65015b1bd4afd2ec50700aaacf2e0c485/library/std/src/../../backtrace/src/backtrace/mod.rs:66:5
 2:     0x71d0020346cf - std::backtrace::Backtrace::create::hde75383bf24709d3
                             at /rustc/a165f1f65015b1bd4afd2ec50700aaacf2e0c485/library/std/src/backtrace.rs:331:13
 3:     0x71d002034610 - std::backtrace::Backtrace::force_capture::he76315b7b93186cf
                             at /rustc/a165f1f65015b1bd4afd2ec50700aaacf2e0c485/library/std/src/backtrace.rs:312:9
 4:     0x71cffeaa7e84 - std[d99a67f26152ed04]::panicking::update_hook::<alloc[3da730520fd9e9f]::boxed::Box<rustc_driver_impl[32be582443c69875]::install_ice_hook::{closure#0}>>::{closure#0}
 5:     0x71d00204f930 - <alloc::boxed::Box<F,A> as core::ops::function::Fn<Args>>::call::h3123ef48483f5a9f
                             at /rustc/a165f1f65015b1bd4afd2ec50700aaacf2e0c485/library/alloc/src/boxed.rs:2034:9
 6:     0x71d00204f930 - std::panicking::rust_panic_with_hook::hc8ea6fc0780cadf2
                             at /rustc/a165f1f65015b1bd4afd2ec50700aaacf2e0c485/library/std/src/panicking.rs:783:13
 7:     0x71d00204f672 - std::panicking::begin_panic_handler::{{closure}}::hbadcf855f0ac336d
                             at /rustc/a165f1f65015b1bd4afd2ec50700aaacf2e0c485/library/std/src/panicking.rs:657:13
 8:     0x71d00204cbc6 - std::sys_common::backtrace::__rust_end_short_backtrace::hd709bf062ed2b8bd
                             at /rustc/a165f1f65015b1bd4afd2ec50700aaacf2e0c485/library/std/src/sys_common/backtrace.rs:171:18
 9:     0x71d00204f3a4 - rust_begin_unwind
                             at /rustc/a165f1f65015b1bd4afd2ec50700aaacf2e0c485/library/std/src/panicking.rs:645:5
10:     0x71d002099d15 - core::panicking::panic_fmt::hc88aa6bdd27ff112
                             at /rustc/a165f1f65015b1bd4afd2ec50700aaacf2e0c485/library/core/src/panicking.rs:72:14
11:     0x71d00155e263 - <rustc_feature[435d5b53c86da6fd]::unstable::Features>::active.cold.0
12:     0x71cfffe2c1d6 - <rustc_lint[16f6928cb0a24f44]::levels::LintLevelsBuilder<rustc_lint[16f6928cb0a24f44]::levels::TopDown>>::check_gated_lint
13:     0x71cfffe2a7d0 - <rustc_lint[16f6928cb0a24f44]::levels::LintLevelsBuilder<rustc_lint[16f6928cb0a24f44]::levels::TopDown>>::push
14:     0x71cffedabd69 - rustc_lint[16f6928cb0a24f44]::early::check_ast_node_inner::<rustc_lint[16f6928cb0a24f44]::early::RuntimeCombinedEarlyLintPass, (&rustc_ast[b2baecc575d35278]::ast::Crate, &[rustc_ast[b2baecc575d35278]::ast::Attribute])>
15:     0x71d000759c79 - rustc_interface[d25bff95c4ca47a9]::passes::resolver_for_lowering_raw
16:     0x71d00075844d - rustc_query_impl[583025ad343be4b9]::plumbing::__rust_begin_short_backtrace::<rustc_query_impl[583025ad343be4b9]::query_impl::resolver_for_lowering_raw::dynamic_query::{closure#2}::{closure#0}, rustc_middle[2167abb34cd9315b]::query::erase::Erased<[u8; 16usize]>>
17:     0x71d00075842d - <rustc_query_impl[583025ad343be4b9]::query_impl::resolver_for_lowering_raw::dynamic_query::{closure#2} as core[d2efe8fd8090ae32]::ops::function::FnOnce<(rustc_middle[2167abb34cd9315b]::ty::context::TyCtxt, ())>>::call_once
18:     0x71d0009b380e - rustc_query_system[a066d69301dbd3df]::query::plumbing::try_execute_query::<rustc_query_impl[583025ad343be4b9]::DynamicConfig<rustc_query_system[a066d69301dbd3df]::query::caches::SingleCache<rustc_middle[2167abb34cd9315b]::query::erase::Erased<[u8; 16usize]>>, false, false, false>, rustc_query_impl[583025ad343be4b9]::plumbing::QueryCtxt, true>
19:     0x71d0009b453b - rustc_query_impl[583025ad343be4b9]::query_impl::resolver_for_lowering_raw::get_query_incr::__rust_end_short_backtrace
20:     0x71d000df2ced - rustc_interface[d25bff95c4ca47a9]::interface::run_compiler::<core[d2efe8fd8090ae32]::result::Result<(), rustc_span[7af1910a94d968b0]::ErrorGuaranteed>, rustc_driver_impl[32be582443c69875]::run_compiler::{closure#0}>::{closure#0}
21:     0x71d000deb217 - std[d99a67f26152ed04]::sys_common::backtrace::__rust_begin_short_backtrace::<rustc_interface[d25bff95c4ca47a9]::util::run_in_thread_with_globals<rustc_interface[d25bff95c4ca47a9]::util::run_in_thread_pool_with_globals<rustc_interface[d25bff95c4ca47a9]::interface::run_compiler<core[d2efe8fd8090ae32]::result::Result<(), rustc_span[7af1910a94d968b0]::ErrorGuaranteed>, rustc_driver_impl[32be582443c69875]::run_compiler::{closure#0}>::{closure#0}, core[d2efe8fd8090ae32]::result::Result<(), rustc_span[7af1910a94d968b0]::ErrorGuaranteed>>::{closure#0}, core[d2efe8fd8090ae32]::result::Result<(), rustc_span[7af1910a94d968b0]::ErrorGuaranteed>>::{closure#0}::{closure#0}, core[d2efe8fd8090ae32]::result::Result<(), rustc_span[7af1910a94d968b0]::ErrorGuaranteed>>
22:     0x71d000deb044 - <<std[d99a67f26152ed04]::thread::Builder>::spawn_unchecked_<rustc_interface[d25bff95c4ca47a9]::util::run_in_thread_with_globals<rustc_interface[d25bff95c4ca47a9]::util::run_in_thread_pool_with_globals<rustc_interface[d25bff95c4ca47a9]::interface::run_compiler<core[d2efe8fd8090ae32]::result::Result<(), rustc_span[7af1910a94d968b0]::ErrorGuaranteed>, rustc_driver_impl[32be582443c69875]::run_compiler::{closure#0}>::{closure#0}, core[d2efe8fd8090ae32]::result::Result<(), rustc_span[7af1910a94d968b0]::ErrorGuaranteed>>::{closure#0}, core[d2efe8fd8090ae32]::result::Result<(), rustc_span[7af1910a94d968b0]::ErrorGuaranteed>>::{closure#0}::{closure#0}, core[d2efe8fd8090ae32]::result::Result<(), rustc_span[7af1910a94d968b0]::ErrorGuaranteed>>::{closure#1} as core[d2efe8fd8090ae32]::ops::function::FnOnce<()>>::call_once::{shim:vtable#0}
23:     0x71d002059135 - <alloc::boxed::Box<F,A> as core::ops::function::FnOnce<Args>>::call_once::h5044a91960b98ce7
                             at /rustc/a165f1f65015b1bd4afd2ec50700aaacf2e0c485/library/alloc/src/boxed.rs:2020:9
24:     0x71d002059135 - <alloc::boxed::Box<F,A> as core::ops::function::FnOnce<Args>>::call_once::hcd8b5448afe6ea4e
                             at /rustc/a165f1f65015b1bd4afd2ec50700aaacf2e0c485/library/alloc/src/boxed.rs:2020:9
25:     0x71d002059135 - std::sys::pal::unix::thread::Thread::new::thread_start::hd4b31b2f3db552cc
                             at /rustc/a165f1f65015b1bd4afd2ec50700aaacf2e0c485/library/std/src/sys/pal/unix/thread.rs:108:17
26:     0x71cffbaa955a - <unknown>
27:     0x71cffbb26a3c - <unknown>
28:                0x0 - <unknown>


rustc version: 1.78.0-nightly (a165f1f65 2024-03-12)
platform: x86_64-unknown-linux-gnu

query stack during panic:
#0 [resolver_for_lowering_raw] getting the resolver for lowering
end of query stack

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-bugCategory: This is a bug.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.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions