summaryrefslogtreecommitdiff
path: root/gcc/testsuite/rust/compile/torture/bools_eq.rs
blob: 965127b5d542d1dec031872b72d3215de951f7b6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
extern "C"
{
  fn abort ();
}

fn beq (a: bool, b: bool) -> bool
{
  let bools_eq = a == b;
  bools_eq
}

pub fn main ()
{
  let a = true;
  let b = false;
  let r = beq (a, b);
  if r { unsafe { abort (); } }
}