aboutsummaryrefslogtreecommitdiff
path: root/src/test/run-pass/constrained-type.rs
blob: ba79c8e4f612b411436ae6e633f7a88be885c083 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
// xfail-boot
// xfail-stage0
// xfail-stage1
// xfail-stage2
// -*- rust -*-

// Reported as issue #141, as a parse error. Ought to work in full though.

tag list {
  cons(int,@list);
  nil();
}

type bubu = rec(int x, int y);


fn less_than(int x, int y) -> bool { ret x < y; }

type ordered_range = rec(int low, int high) : less_than(*.low, *.high);

fn main() {
}