about summary refs log tree commit diff
path: root/tests/ui/rfcs/rfc-0000-never_patterns/check_place_is_initialized.rs
blob: f8f9d7a9aa6ce8ecfa8a1cf77cd0b68d1ba5ade2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
#![feature(never_patterns)]
#![allow(incomplete_features)]

enum Void {}

fn main() {}

fn anything<T>() -> T {
    let x: Void;
    match x { ! }
    //~^ ERROR used binding `x` isn't initialized
}