rust/src/test/compile-fail/pred-not-bool.rs
Tim Chevalier 6b742aec91 Enforce in typechecker that preds return a bool
as well as a test case
2011-05-05 11:26:07 -07:00

16 lines
245 B
Rust

// -*- rust -*-
// xfail-boot
// xfail-stage0
// error-pattern: Non-boolean return type
// this checks that a pred with a non-bool return
// type is rejected, even if the pred is never used
pred bad(int a) -> int {
ret 37;
}
fn main() {
}