Remove typestate test
This commit is contained in:
parent
f67904ca40
commit
1f81e4cbc6
@ -1,16 +0,0 @@
|
||||
// -*- rust -*-
|
||||
// xfail-test
|
||||
// error-pattern:Unsatisfied precondition
|
||||
|
||||
pure fn less_than(x: int, y: int) -> bool { return x < y; }
|
||||
|
||||
type ordered_range = {low: int, high: int} : less_than(*.low, *.high);
|
||||
|
||||
fn main() {
|
||||
// Should fail to compile, b/c we're not doing the check
|
||||
// explicitly that a < b
|
||||
let a: int = 1;
|
||||
let b: int = 2;
|
||||
let c: ordered_range = {low: a, high: b};
|
||||
log(debug, c.low);
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user