Skip to content
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

ICE with ref pattern on integers #33499

Closed
Manishearth opened this issue May 8, 2016 · 1 comment
Closed

ICE with ref pattern on integers #33499

Manishearth opened this issue May 8, 2016 · 1 comment
Labels
I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️

Comments

@Manishearth
Copy link
Member

fn main() {
    let x = (0,2);
    match x {
        (0, ref y) => { /* use y */}
        (y, 0) => { /* use y */ }
        _ => ()
    }
}

playpen

This causes an ICE at error: internal compiler error: ../src/librustc_trans/_match.rs:944: only string and byte strings supported in compare_values on stable, beta, and nightly.

It goes away if you swap the match arms.

@Manishearth Manishearth added the I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️ label May 8, 2016
@jonas-schievink
Copy link
Contributor

Duplicate of #33498

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

No branches or pull requests

2 participants