Skip to content

internal compiler error: ident only path should have been covered already #22972

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

Closed
Hansyperman opened this issue Mar 2, 2015 · 1 comment · Fixed by #23930
Closed

internal compiler error: ident only path should have been covered already #22972

Hansyperman opened this issue Mar 2, 2015 · 1 comment · Fixed by #23930
Labels
I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️

Comments

@Hansyperman
Copy link

$ cat testje.rs
fn main(){
    let mut v=std::vec::Vec::<isize>::new();
    v.push(1);
    v.push(2);
    // The next line makes rust crash.  It does not make any sense (it was just a typo) but thought i'd report it anyway.
    let v[0]=v[1];
}

$ rustc --version
rustc 1.0.0-nightly (890293655 2015-02-28) (built 2015-03-01)

$ RUST_BACKTRACE=1 rustc testje.rs
testje.rs:6:9: 6:10 error: internal compiler error: ident only path should have been covered already
testje.rs:6     let v[0]=v[1];
                    ^
note: the compiler unexpectedly panicked. this is a bug.
note: we would appreciate a bug report: https://github.com/rust-lang/rust/blob/master/CONTRIBUTING.md#bug-reports
note: run with `RUST_BACKTRACE=1` for a backtrace
thread 'rustc' panicked at 'Box<Any>', /home/rustbuild/src/rust-buildbot/slave/nightly-dist-rustc-linux/build/src/libsyntax/diagnostic.rs:129

stack backtrace:
   1:         0x577a6c4f - sys::backtrace::write::hb08af03691eab78a5kA
   2:         0x577cf782 - panicking::on_panic::h37164609ca1c02afBnJ
   3:         0x5770f63a - rt::unwind::begin_unwind_inner::h24d5e7492198457b43I
   4:         0x54a55a8d - rt::unwind::begin_unwind::h9113908695753286194
   5:         0x54a55a33 - diagnostic::SpanHandler::span_bug::hcbc27df468564853WBD
   6:         0x54a7b905 - parse::parser::Parser<'a>::parse_pat::hf7a2ebdbbed007b1d3J
   7:         0x54a8df2d - parse::parser::Parser<'a>::parse_local::h7d6c62c9c63efba1xkK
   8:         0x54a8f22f - parse::parser::Parser<'a>::parse_stmt::h622ba475055891c9inK
   9:         0x54a97e89 - parse::parser::Parser<'a>::parse_block_tail_::hb2f43cc30c93d511ryK
  10:         0x54a75dec - parse::parser::Parser<'a>::parse_inner_attrs_and_block::h554d87549b4ccdacTwK
  11:         0x54a9c465 - parse::parser::Parser<'a>::parse_item_fn::hbda705c8fc5a7ac1icL
  12:         0x54a92778 - parse::parser::Parser<'a>::parse_item_::hf9f9cf23aa0f1cd4iaM
  13:         0x54aa2985 - parse::parser::Parser<'a>::parse_mod_items::habe606a27fa5b86dSAL
  14:         0x54aacc6c - parse::parser::Parser<'a>::parse_crate_mod::h8c08698d71a0eba6PAM
  15:         0x54abf61e - parse::parse_crate_from_file::ha077e55f357e36faJNT
  16:         0x57e341b1 - driver::phase_1_parse_input::closure.15399
  17:         0x57e0e7b7 - driver::phase_1_parse_input::h21d9f24721445c1fvqa
  18:         0x57e0b181 - driver::compile_input::hee81c045ab46c74fIba
  19:         0x57ed6e6e - run_compiler::h875c1e123fe4ae2cF5b
  20:         0x57ed4a1c - thunk::F.Invoke<A, R>::invoke::h12424714292252424185
  21:         0x57ed3770 - rt::unwind::try::try_fn::h4021821266450575721
  22:         0x5783afe8 - rust_try_inner
  23:         0x5783afd5 - rust_try
  24:         0x57ed3e5c - thunk::F.Invoke<A, R>::invoke::h8199562432922027576
  25:         0x577bb2d5 - sys::thread::thread_start::h1b1bb1e7ac08d3a6yRE
  26:         0x5150db4f - start_thread
  27:         0x573a270c - <unknown>

There are a few issues with the same error message, but they seem to have been fixed before my nightly - and the way to cause it is also different

@kmcallister kmcallister added the I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️ label Mar 2, 2015
@Kimundi
Copy link
Member

Kimundi commented Mar 22, 2015

See #22426

bors added a commit that referenced this issue Apr 3, 2015
Fixes #22757
Fixes #22972
Fixes #23044
Fixes #23151
Fixes #23597
Fixes #23656
Fixes #23929
It also fixes some other corner cases in range patterns, like incorrect spans or not accepting global paths after `...`.

It passes `make check` but needs some additional tests (then it will fix #22546 as well), I'll write them today or tomorrow.
Manishearth added a commit to Manishearth/rust that referenced this issue Apr 3, 2015
Fixes rust-lang#22757
Fixes rust-lang#22972
Fixes rust-lang#23044
Fixes rust-lang#23151
Fixes rust-lang#23597
Fixes rust-lang#23656
Fixes rust-lang#23929
It also fixes some other corner cases in range patterns, like incorrect spans or not accepting global paths after `...`.

It passes `make check` but needs some additional tests (then it will fix rust-lang#22546 as well), I'll write them today or tomorrow.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants