aboutsummaryrefslogtreecommitdiff
path: root/src/test/compile-fail/use-uninit-2.rs
blob: d8e9ef804532554f1ccf6fe594ca557a2ea398e5 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
// error-pattern::Unsatisfied precondition

fn foo(int x) {
  log x;
}

fn main() {
  let int x;
  if (1 > 2) {
    x = 10;
  }
  foo(x);
}