| 1 |
Wildcard. |
| 2 |
|
| 3 |
$ bash ../test.sh <<'EOF' |
| 4 |
> let _ = |
| 5 |
> match () with |
| 6 |
> | _ -> () |
| 7 |
> EOF |
| 8 |
let _ = |
| 9 |
match () with |
| 10 |
| _ -> |
| 11 |
___bisect_visit___ 0; |
| 12 |
() |
| 13 |
|
| 14 |
|
| 15 |
Variable. |
| 16 |
|
| 17 |
$ bash ../test.sh <<'EOF' |
| 18 |
> let _ = |
| 19 |
> match () with |
| 20 |
> | x -> x |
| 21 |
> EOF |
| 22 |
let _ = |
| 23 |
match () with |
| 24 |
| x -> |
| 25 |
___bisect_visit___ 0; |
| 26 |
x |
| 27 |
|
| 28 |
|
| 29 |
Nullary constructor. |
| 30 |
|
| 31 |
$ bash ../test.sh <<'EOF' |
| 32 |
> let _ = |
| 33 |
> match () with |
| 34 |
> | () -> () |
| 35 |
> EOF |
| 36 |
let _ = |
| 37 |
match () with |
| 38 |
| () -> |
| 39 |
___bisect_visit___ 0; |
| 40 |
() |
| 41 |
|
| 42 |
|
| 43 |
Constant. |
| 44 |
|
| 45 |
$ bash ../test.sh <<'EOF' |
| 46 |
> let _ = |
| 47 |
> match 0 with |
| 48 |
> | 0 -> () |
| 49 |
> | _ -> () |
| 50 |
> EOF |
| 51 |
let _ = |
| 52 |
match 0 with |
| 53 |
| 0 -> |
| 54 |
___bisect_visit___ 0; |
| 55 |
() |
| 56 |
| _ -> |
| 57 |
___bisect_visit___ 1; |
| 58 |
() |
| 59 |
|
| 60 |
|
| 61 |
Interval. |
| 62 |
|
| 63 |
$ bash ../test.sh <<'EOF' |
| 64 |
> let _ = |
| 65 |
> match 'a' with |
| 66 |
> | 'a'..'z' -> () |
| 67 |
> | _ -> () |
| 68 |
> EOF |
| 69 |
let _ = |
| 70 |
match 'a' with |
| 71 |
| 'a' .. 'z' -> |
| 72 |
___bisect_visit___ 0; |
| 73 |
() |
| 74 |
| _ -> |
| 75 |
___bisect_visit___ 1; |
| 76 |
() |
| 77 |
|
| 78 |
|
| 79 |
Nullary polymorphic variand. |
| 80 |
|
| 81 |
$ bash ../test.sh <<'EOF' |
| 82 |
> let _ = |
| 83 |
> match `A with |
| 84 |
> | `A -> () |
| 85 |
> EOF |
| 86 |
let _ = |
| 87 |
match `A with |
| 88 |
| `A -> |
| 89 |
___bisect_visit___ 0; |
| 90 |
() |
| 91 |
|
| 92 |
|
| 93 |
Polymorphic variant type name. |
| 94 |
|
| 95 |
$ bash ../test.sh <<'EOF' |
| 96 |
> type t = [ `A ] |
| 97 |
> let _ = |
| 98 |
> match `A with |
| 99 |
> | #t -> () |
| 100 |
> EOF |
| 101 |
type t = [ `A ] |
| 102 |
|
| 103 |
let _ = |
| 104 |
match `A with |
| 105 |
| #t -> |
| 106 |
___bisect_visit___ 0; |
| 107 |
() |
| 108 |
|
| 109 |
|
| 110 |
Module. |
| 111 |
|
| 112 |
$ bash ../test.sh <<'EOF' |
| 113 |
> module type L = module type of List |
| 114 |
> let _ = |
| 115 |
> match (module List : L) with |
| 116 |
> | (module L) -> () |
| 117 |
> EOF |
| 118 |
module type L = module type of List |
| 119 |
|
| 120 |
let _ = |
| 121 |
match (module List : L) with |
| 122 |
| (module L) -> |
| 123 |
___bisect_visit___ 0; |
| 124 |
() |