Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

could not compile time use nightly version #99343

Closed
fundon opened this issue Jul 16, 2022 · 1 comment
Closed

could not compile time use nightly version #99343

fundon opened this issue Jul 16, 2022 · 1 comment
Labels
C-bug Category: This is a bug. I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️ T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.

Comments

@fundon
Copy link

fundon commented Jul 16, 2022

My project: https://github.com/viz-rs/viz
Tested successfully in stable version.
Built failed: https://docs.rs/crate/viz/0.2.0-alpha/builds/594250

Code

RUST_BACKTRACE=1 cargo test

Meta

rustc --version --verbose:

rustc 1.64.0-nightly (23e21bdd2 2022-07-15)
binary: rustc
commit-hash: 23e21bdd25026e2839ebe946c2a937c1904887d2
commit-date: 2022-07-15
host: x86_64-apple-darwin
release: 1.64.0-nightly
LLVM version: 14.0.6

Error output

λ cargo test
   Compiling crypto-common v0.1.5
   Compiling block-buffer v0.10.2
   Compiling time v0.3.11
   Compiling rand_chacha v0.3.1
   Compiling serde v1.0.139
   Compiling thiserror v1.0.31
   Compiling tokio v1.20.0
   Compiling futures-util v0.3.21
   Compiling tracing v0.1.35
   Compiling digest v0.10.3
   Compiling mime_guess v2.0.4
   Compiling rand v0.8.5
thread 'rustc' panicked at 'index out of bounds: the len is 1 but the index is 2', compiler/rustc_builtin_macros/src/format.rs:1001:28
stack backtrace:
   0:        0x1069b5ca4 - <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt::h4d86da9d3736a52d
   1:        0x106a0d68b - core::fmt::write::h4100c91e34b46860
   2:        0x1069a845c - std::io::Write::write_fmt::hbebacfc28bcb7e63
   3:        0x1069b8d77 - std::panicking::default_hook::{{closure}}::hd1401e79e66368b2
   4:        0x1069b8a80 - std::panicking::default_hook::h0d3c0f46f3eb5b87
   5:        0x1112c8e5a - rustc_driver[73f94c78c1d7d2d0]::DEFAULT_HOOK::{closure#0}::{closure#0}
   6:        0x1069b94ad - std::panicking::rust_panic_with_hook::h79b08049599e7781
   7:        0x1069b9353 - std::panicking::begin_panic_handler::{{closure}}::h6759a4e79ddd7d62
   8:        0x1069b6157 - std::sys_common::backtrace::__rust_end_short_backtrace::ha49d7b96ae0f3fdf
   9:        0x1069b902d - _rust_begin_unwind
  10:        0x106a389f3 - core::panicking::panic_fmt::hc9b2ac84f45a78f2
  11:        0x106a38946 - core::panicking::panic_bounds_check::hd73082592787ac04
  12:        0x113d54272 - rustc_builtin_macros[4c4cf493c0067ce6]::format::expand_preparsed_format_args
  13:        0x113d4c9db - rustc_builtin_macros[4c4cf493c0067ce6]::format::expand_format_args_impl
  14:        0x11523ce44 - <rustc_expand[219fa54abb38e138]::expand::MacroExpander>::fully_expand_fragment
  15:        0x11523c15f - <rustc_expand[219fa54abb38e138]::expand::MacroExpander>::expand_crate
  16:        0x1113898d6 - <rustc_session[6a4c6fef4db8af12]::session::Session>::time::<core[4765b6e14de13592]::result::Result<rustc_ast[941672277c0de11b]::ast::Crate, rustc_errors[6b560b2f72f0dc1a]::ErrorGuaranteed>, rustc_interface[8a17d161f34c737e]::passes::configure_and_expand::{closure#1}>
  17:        0x111380a23 - <rustc_interface[8a17d161f34c737e]::passes::boxed_resolver::BoxedResolver>::access::<<rustc_interface[8a17d161f34c737e]::queries::Queries>::expansion::{closure#0}::{closure#0}, core[4765b6e14de13592]::result::Result<rustc_ast[941672277c0de11b]::ast::Crate, rustc_errors[6b560b2f72f0dc1a]::ErrorGuaranteed>>
  18:        0x111362526 - <rustc_interface[8a17d161f34c737e]::queries::Queries>::expansion
  19:        0x111243ef1 - <rustc_interface[8a17d161f34c737e]::interface::Compiler>::enter::<rustc_driver[73f94c78c1d7d2d0]::run_compiler::{closure#1}::{closure#2}, core[4765b6e14de13592]::result::Result<core[4765b6e14de13592]::option::Option<rustc_interface[8a17d161f34c737e]::queries::Linker>, rustc_errors[6b560b2f72f0dc1a]::ErrorGuaranteed>>
  20:        0x1112397f8 - rustc_span[b3c07a240d8aa70d]::with_source_map::<core[4765b6e14de13592]::result::Result<(), rustc_errors[6b560b2f72f0dc1a]::ErrorGuaranteed>, rustc_interface[8a17d161f34c737e]::interface::create_compiler_and_run<core[4765b6e14de13592]::result::Result<(), rustc_errors[6b560b2f72f0dc1a]::ErrorGuaranteed>, rustc_driver[73f94c78c1d7d2d0]::run_compiler::{closure#1}>::{closure#1}>
  21:        0x111263cf6 - rustc_interface[8a17d161f34c737e]::interface::create_compiler_and_run::<core[4765b6e14de13592]::result::Result<(), rustc_errors[6b560b2f72f0dc1a]::ErrorGuaranteed>, rustc_driver[73f94c78c1d7d2d0]::run_compiler::{closure#1}>
  22:        0x111236825 - <scoped_tls[bbf5cad6a1edfb51]::ScopedKey<rustc_span[b3c07a240d8aa70d]::SessionGlobals>>::set::<rustc_interface[8a17d161f34c737e]::interface::run_compiler<core[4765b6e14de13592]::result::Result<(), rustc_errors[6b560b2f72f0dc1a]::ErrorGuaranteed>, rustc_driver[73f94c78c1d7d2d0]::run_compiler::{closure#1}>::{closure#0}, core[4765b6e14de13592]::result::Result<(), rustc_errors[6b560b2f72f0dc1a]::ErrorGuaranteed>>
  23:        0x111240469 - std[51cc303cb6d2584d]::sys_common::backtrace::__rust_begin_short_backtrace::<rustc_interface[8a17d161f34c737e]::util::run_in_thread_pool_with_globals<rustc_interface[8a17d161f34c737e]::interface::run_compiler<core[4765b6e14de13592]::result::Result<(), rustc_errors[6b560b2f72f0dc1a]::ErrorGuaranteed>, rustc_driver[73f94c78c1d7d2d0]::run_compiler::{closure#1}>::{closure#0}, core[4765b6e14de13592]::result::Result<(), rustc_errors[6b560b2f72f0dc1a]::ErrorGuaranteed>>::{closure#0}, core[4765b6e14de13592]::result::Result<(), rustc_errors[6b560b2f72f0dc1a]::ErrorGuaranteed>>
  24:        0x111264a01 - <<std[51cc303cb6d2584d]::thread::Builder>::spawn_unchecked_<rustc_interface[8a17d161f34c737e]::util::run_in_thread_pool_with_globals<rustc_interface[8a17d161f34c737e]::interface::run_compiler<core[4765b6e14de13592]::result::Result<(), rustc_errors[6b560b2f72f0dc1a]::ErrorGuaranteed>, rustc_driver[73f94c78c1d7d2d0]::run_compiler::{closure#1}>::{closure#0}, core[4765b6e14de13592]::result::Result<(), rustc_errors[6b560b2f72f0dc1a]::ErrorGuaranteed>>::{closure#0}, core[4765b6e14de13592]::result::Result<(), rustc_errors[6b560b2f72f0dc1a]::ErrorGuaranteed>>::{closure#1} as core[4765b6e14de13592]::ops::function::FnOnce<()>>::call_once::{shim:vtable#0}
  25:        0x1069c2187 - std::sys::unix::thread::Thread::new::thread_start::hae41e3c2653ceb35
  26:     0x7ff81efb84e1 - __pthread_start

error: internal compiler error: unexpected panic

note: the compiler unexpectedly panicked. this is a bug.

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.64.0-nightly (23e21bdd2 2022-07-15) running on x86_64-apple-darwin

note: compiler flags: --crate-type rlib -C embed-bitcode=no -C split-debuginfo=unpacked -C debuginfo=2 -C linker=clang -C link-arg=-undefined -C link-arg=dynamic_lookup

note: some of the compiler flags provided by cargo are hidden

query stack during panic:
end of query stack
error: could not compile `time`

Backtrace

λ RUST_BACKTRACE=1 cargo test
   Compiling time v0.3.11
   Compiling sha-1 v0.10.0
   Compiling serde_json v1.0.82
   Compiling serde_urlencoded v0.7.1
   Compiling toml v0.5.9
   Compiling tokio-stream v0.1.9
   Compiling tokio-util v0.7.3
   Compiling form-data v0.4.0
   Compiling hyper v0.14.20
   Compiling tungstenite v0.17.3
   Compiling headers v0.3.7
thread 'rustc' panicked at 'index out of bounds: the len is 1 but the index is 2', compiler/rustc_builtin_macros/src/format.rs:1001:28
stack backtrace:
   0: _rust_begin_unwind
   1: core::panicking::panic_fmt
   2: core::panicking::panic_bounds_check
   3: rustc_builtin_macros::format::expand_preparsed_format_args
   4: rustc_builtin_macros::format::expand_format_args_impl
   5: <rustc_expand::expand::MacroExpander>::fully_expand_fragment
   6: <rustc_expand::expand::MacroExpander>::expand_crate
   7: <rustc_session::session::Session>::time::<core::result::Result<rustc_ast::ast::Crate, rustc_errors::ErrorGuaranteed>, rustc_interface::passes::configure_and_expand::{closure#1}>
   8: <rustc_interface::passes::boxed_resolver::BoxedResolver>::access::<<rustc_interface::queries::Queries>::expansion::{closure#0}::{closure#0}, core::result::Result<rustc_ast::ast::Crate, rustc_errors::ErrorGuaranteed>>
   9: <rustc_interface::queries::Queries>::expansion
  10: <rustc_interface::interface::Compiler>::enter::<rustc_driver::run_compiler::{closure#1}::{closure#2}, core::result::Result<core::option::Option<rustc_interface::queries::Linker>, rustc_errors::ErrorGuaranteed>>
  11: rustc_span::with_source_map::<core::result::Result<(), rustc_errors::ErrorGuaranteed>, rustc_interface::interface::create_compiler_and_run<core::result::Result<(), rustc_errors::ErrorGuaranteed>, rustc_driver::run_compiler::{closure#1}>::{closure#1}>
  12: rustc_interface::interface::create_compiler_and_run::<core::result::Result<(), rustc_errors::ErrorGuaranteed>, rustc_driver::run_compiler::{closure#1}>
  13: <scoped_tls::ScopedKey<rustc_span::SessionGlobals>>::set::<rustc_interface::interface::run_compiler<core::result::Result<(), rustc_errors::ErrorGuaranteed>, rustc_driver::run_compiler::{closure#1}>::{closure#0}, core::result::Result<(), rustc_errors::ErrorGuaranteed>>
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

error: internal compiler error: unexpected panic

note: the compiler unexpectedly panicked. this is a bug.

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.64.0-nightly (23e21bdd2 2022-07-15) running on x86_64-apple-darwin

note: compiler flags: --crate-type rlib -C embed-bitcode=no -C split-debuginfo=unpacked -C debuginfo=2 -C linker=clang -C link-arg=-undefined -C link-arg=dynamic_lookup

note: some of the compiler flags provided by cargo are hidden

query stack during panic:
end of query stack
error: could not compile `time`
warning: build failed, waiting for other jobs to finish...

@fundon fundon added C-bug Category: This is a bug. I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️ T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Jul 16, 2022
@ehuss
Copy link
Contributor

ehuss commented Jul 16, 2022

Thanks for the report! Closing as a duplicate of #99261. This should be fixed by #99263 and should be in the next nightly.

@ehuss ehuss closed this as not planned Won't fix, can't repro, duplicate, stale Jul 16, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-bug Category: This is a bug. I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️ T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

No branches or pull requests

2 participants