Skip to content

Fails silently: match 1 {1 => 3, 2u => 4} #6209

Closed
@ssbr

Description

@ssbr

Putting that code somewhere in a project will result in a failure to build, but (at least in rust 0.6, on windows) no error message.

Consider this shell session in mingw:

$ cat > test_mod.rs
fn main() {match 1 {1 => 3, 2u => 4};}
$ rustc.exe test_mod.rs
$ echo $?
101
$ RUST_LOG=rustc=1,::rt::backtrace rustc.exe test_mod.rs
rust: task failed at 'compare_const_vals: ill-typed comparison', C:\bot\slave\dist-win\build\src\librustc\middle\const_eval.rs:477
rust: domain main @0x459278 root task failed

Metadata

Metadata

Assignees

No one assigned

    Labels

    I-ICEIssue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions