2011-05-04 11:32:06 -07:00
|
|
|
// -*- rust -*-
|
2011-06-20 17:29:54 -07:00
|
|
|
// error-pattern: Pure function calls function not known to be pure
|
2011-05-04 11:32:06 -07:00
|
|
|
|
2011-07-27 14:19:39 +02:00
|
|
|
fn g() { }
|
2011-05-04 11:32:06 -07:00
|
|
|
|
2011-07-27 14:19:39 +02:00
|
|
|
pred f(q: int) -> bool { g(); ret true; }
|
2011-05-04 11:32:06 -07:00
|
|
|
|
|
|
|
fn main() {
|
2011-07-27 14:19:39 +02:00
|
|
|
let x = 0;
|
2011-05-04 11:32:06 -07:00
|
|
|
|
2011-07-27 14:19:39 +02:00
|
|
|
check (f(x));
|
|
|
|
}
|