rust-lang / rust-lang/rust-clippy
[bug] compile panicked unexpectly at rustc_metadata
Open
Nobody has claimed this yet.
E-needs-mcve
I-ICE
- Dominant language
- Rust
- Stars
- 13.5k
- Forks
- 2.2k
- Avg merge
- 2d 10h
- Merged PRs (30d)
- 32
Description
this happens on a cargo build with one of our internal crates
thread 'rustc' panicked at 'called `Option::unwrap()` on a `None` value', compiler/rustc_metadata/src/rmeta/def_path_hash_map.rs:18:85
note: run with `RUST_BACKTRACE=1` environment variable to display a 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-clippy/issues/new
note: Clippy version: clippy 0.1.60 (7737e0b 2022-04-04)
query stack during panic:
#0 [evaluate_obligation] evaluating trait selection obligation `impl core::future::future::Future<Output = connection_pool::endpoint_pool::EndpointPool<pool_roblox::PoolConnectionManager>>: core::marker::Send`
#1 [analysis] running analysis passes on this crate
end of query stack
error: could not compile `cockroachdb-pool`
warning: build failed, waiting for other jobs to finish...
thread 'rustc' panicked at 'called `Option::unwrap()` on a `None` value', compiler/rustc_metadata/src/rmeta/def_path_hash_map.rs:18:85
note: run with `RUST_BACKTRACE=1` environment variable to display a 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-clippy/issues/new
note: Clippy version: clippy 0.1.60 (7737e0b 2022-04-04)
query stack during panic:
#0 [evaluate_obligation] evaluating trait selection obligation `impl core::future::future::Future<Output = connection_pool::endpoint_pool::EndpointPool<cockroachdb_pool::pool_roblox::PoolConnectionManager>>: core::marker::Send`
#1 [analysis] running analysis passes on this crate
end of query stack
error: build failed
make: *** [Makefile:22: lint] Error 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
Start by reproducing the cargo build failure with the reported internal crate and inspect compiler/rustc_metadata/src/rmeta/def_path_hash_map.rs:18:85. Run with RUST_BACKTRACE=1 and compare the evaluate_obligation query stack for the two panic cases. Done means identifying the triggering metadata condition and confirming that the compiler no longer panics during analysis.
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
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100