Skip to content

nightly ICE: panicked at 'index out of bounds: the len is 0 but the index is 1', /checkout/src/liballoc/vec.rs:1564:14 #44021

Closed
@zhendongsu

Description

@zhendongsu

The test also causes 1.18 and 1.19 to loop indefinitely.

$ rustc-nightly --version
rustc 1.21.0-nightly (8c303ed87 2017-08-20)
$ 
$ rustc-nightly tmp.rs
error: expected expression, found `}`
 --> tmp.rs:4:1
  |
4 | } 
  | ^

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/blob/master/CONTRIBUTING.md#bug-reports

note: rustc 1.21.0-nightly (8c303ed87 2017-08-20) running on i686-unknown-linux-gnu

thread 'rustc' panicked at 'index out of bounds: the len is 0 but the index is 1', /checkout/src/liballoc/vec.rs:1564:14
note: Run with `RUST_BACKTRACE=1` for a backtrace.

$ 
$ cat tmp.rs
impl Struct
{ 
  fn static_meth_struct () -> Struct {|} 
} 
$ 

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