thread 'rustc' panicked at 'begin <= end (2 <= 0) when slicing · Issue #71471 · rust-lang/rust (original) (raw)

Skip to content

Provide feedback

Saved searches

Use saved searches to filter your results more quickly

Sign up

Appearance settings

@dwrensha

Description

@dwrensha

I'm seeing an internal compiler error on the input "\n#!B\n" (found by fuzz-rustc):

$ cat main.rs

#!B
$ rustc main.rs
thread 'rustc' panicked at 'begin <= end (2 <= 0) when slicing `
#!B
`', /rustc/b2e36e6c2d229126b59e892c9147fbb68115d292/src/libcore/str/mod.rs:1920:47
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/blob/master/CONTRIBUTING.md#bug-reports

note: rustc 1.44.0-nightly (b2e36e6c2 2020-04-22) running on x86_64-unknown-linux-gnu

This issue has been assigned to @rcoh via this comment.