Skip to content

internal compiler error in check_match.rs #4974

Closed
@Zedzap

Description

@Zedzap

rustc --version
rustc 0.6 (9143688 2013-02-14 14:44:12 -0800)
host: x86_64-unknown-linux-gnu

Found ICE when compiling this snippet:

fn main() {
match 0 {
y if y < 0 => ()
}
}

Here is the backtrace:
rust: task failed at 'Assertion (!pats.is_empty()) failed', .../src/librustc/middle/check_match.rs:135
/usr/bin/../lib/librustrt.so(_ZN9rust_task13begin_failureEPKcS1_m+0x4b)[0x7f7c0fd2aeeb]
/usr/bin/../lib/librustrt.so(+0x2ac29)[0x7f7c0fd3bc29]
/usr/bin/../lib/librustrt.so(upcall_fail+0x180)[0x7f7c0fd2ccf0]
/usr/bin/../lib/libcore-c3ca5d77d81b46c1-0.6.so(+0xf858b)[0x7f7c1187358b]
/usr/bin/../lib/libcore-c3ca5d77d81b46c1-0.6.so(+0x402de)[0x7f7c117bb2de]
/usr/bin/../lib/librustc-c84825241471686d-0.6.so(_ZN6middle11check_match16check_exhaustive16_c41dd2a15ed85183_06E+0xa7f)[0x7f7c1058032f]
/usr/bin/../lib/librustc-c84825241471686d-0.6.so(_ZN6middle11check_match10check_expr17_91da63eec117a1fb3_06E+0x865)[0x7f7c1057c365]
/usr/bin/../lib/librustc-c84825241471686d-0.6.so(+0x3febae)[0x7f7c1036bbae]
/usr/bin/../lib/librustc-c84825241471686d-0.6.so(_ZN6middle11check_match8check_fn17_307b4ac256cbd1fb3_06E+0x153)[0x7f7c1057cd53]
/usr/bin/../lib/librustc-c84825241471686d-0.6.so(+0x60fbf7)[0x7f7c1057cbf7]
/usr/bin/../lib/librustc-c84825241471686d-0.6.so(+0x3fd1e0)[0x7f7c1036a1e0]
/usr/bin/../lib/librustc-c84825241471686d-0.6.so(+0x3fc9c4)[0x7f7c103699c4]
/usr/bin/../lib/librustc-c84825241471686d-0.6.so(_ZN6middle11check_match11check_crate17_4eb7bea3f5c7f29d3_06E+0x439)[0x7f7c1057b3f9]
/usr/bin/../lib/librustc-c84825241471686d-0.6.so(+0x8c17f6)[0x7f7c1082e7f6]
/usr/bin/../lib/librustc-c84825241471686d-0.6.so(+0x908254)[0x7f7c10875254]
/usr/bin/../lib/librustc-c84825241471686d-0.6.so(_ZN6driver6driver12compile_upto17_8d63b5f164a5111b3_06E+0x1d13)[0x7f7c1082a8d3]
/usr/bin/../lib/librustc-c84825241471686d-0.6.so(+0x908254)[0x7f7c10875254]
/usr/bin/../lib/librustc-c84825241471686d-0.6.so(_ZN6driver6driver13compile_input15_ec93634a1749fa3_06E+0xb9)[0x7f7c1082ee19]
/usr/bin/../lib/librustc-c84825241471686d-0.6.so(_ZN12run_compiler16_effc976f5954f613_06E+0x2218)[0x7f7c10860f98]
/usr/bin/../lib/librustc-c84825241471686d-0.6.so(+0x905241)[0x7f7c10872241]
/usr/bin/../lib/librustc-c84825241471686d-0.6.so(+0x90385e)[0x7f7c1087085e]
/usr/bin/../lib/librustc-c84825241471686d-0.6.so(+0x908254)[0x7f7c10875254]
/usr/bin/../lib/libcore-c3ca5d77d81b46c1-0.6.so(+0xc3d74)[0x7f7c1183ed74]
/usr/bin/../lib/libcore-c3ca5d77d81b46c1-0.6.so(+0x129dc0)[0x7f7c118a4dc0]
/usr/bin/../lib/librustrt.so(_Z18task_start_wrapperP10spawn_args+0x24)[0x7f7c0fd2b754]
error: internal compiler error: unexpected failure
note: the compiler hit an unexpected failure path. this is a bug
note: try running with RUST_LOG=rustc=1,::rt::backtrace to get further details and report the results to github.com/mozilla/rust/issues
rust: task failed at 'explicit failure', .../src/librustc/rustc.rc:371
/usr/bin/../lib/librustrt.so(_ZN9rust_task13begin_failureEPKcS1_m+0x4b)[0x7f7c0fd2aeeb]
/usr/bin/../lib/librustrt.so(+0x2ac29)[0x7f7c0fd3bc29]
/usr/bin/../lib/librustrt.so(upcall_fail+0x180)[0x7f7c0fd2ccf0]
/usr/bin/../lib/libcore-c3ca5d77d81b46c1-0.6.so(+0xf858b)[0x7f7c1187358b]
/usr/bin/../lib/libcore-c3ca5d77d81b46c1-0.6.so(+0xf8532)[0x7f7c11873532]
/usr/bin/../lib/libcore-c3ca5d77d81b46c1-0.6.so(_ZN3sys12begin_unwind17_7cd364c41f10422f3_06E+0x71)[0x7f7c117bb771]
/usr/bin/../lib/libcore-c3ca5d77d81b46c1-0.6.so(+0x129dc0)[0x7f7c118a4dc0]
/usr/bin/../lib/librustc-c84825241471686d-0.6.so(_ZN7monitor17_43bc971c43c819df3_06E+0x5fb5)[0x7f7c10867e25]
/usr/bin/../lib/librustc-c84825241471686d-0.6.so(+0x908254)[0x7f7c10875254]
/usr/bin/../lib/librustc-c84825241471686d-0.6.so(_ZN4main16_706f4ee7413ae583_06E+0x7e)[0x7f7c10874e6e]
/usr/bin/../lib/librustrt.so(_Z18task_start_wrapperP10spawn_args+0x24)[0x7f7c0fd2b754]
rust: domain main @0x19dc3b0 root task failed

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions