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