Skip to content

Commit df077a7

Browse files
authored
flambda-backend: Update "shape" tests to new fomat (#2462)
* Update tests to new fomat. * Remove temporary files * Remove temporary files * Promote tests. * Copy upstream's header.
1 parent ac462d4 commit df077a7

23 files changed

+287
-314
lines changed

testsuite/tests/shape-index/index.ml

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,18 @@
11
(* TEST
2-
flags = "-bin-annot -bin-annot-occurrences"
3-
compile_only = "true"
4-
readonly_files = "auxiliaire.ml"
5-
* setup-ocamlc.byte-build-env
6-
all_modules = "auxiliaire.ml index.ml"
7-
** ocamlc.byte
8-
*** check-ocamlc.byte-output
92
10-
program = "-quiet -index -decls index.cmt"
11-
output = "out_objinfo"
3+
flags = "-bin-annot -bin-annot-occurrences";
4+
compile_only = "true";
5+
readonly_files = "auxiliaire.ml";
6+
setup-ocamlc.byte-build-env;
7+
all_modules = "auxiliaire.ml index.ml";
8+
ocamlc.byte;
9+
check-ocamlc.byte-output;
1210
13-
**** ocamlobjinfo
11+
program = "-quiet -index -decls index.cmt";
12+
output = "out_objinfo";
13+
ocamlobjinfo;
1414
15-
**** check-program-output
15+
check-program-output;
1616
*)
1717

1818
module type AS = sig

testsuite/tests/shape-index/index_aliases.ml

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,17 @@
11
(* TEST
2-
3-
flags = "-bin-annot -bin-annot-occurrences"
4-
compile_only = "true"
5-
* setup-ocamlc.byte-build-env
6-
all_modules = "index_aliases.ml"
7-
* ocamlc.byte
8-
** check-ocamlc.byte-output
9-
10-
program = "-quiet -index -decls index_aliases.cmt"
11-
output = "out_objinfo"
12-
*** ocamlobjinfo
13-
14-
**** check-program-output
2+
flags = "-bin-annot -bin-annot-occurrences";
3+
compile_only = "true";
4+
{
5+
all_modules = "index_aliases.ml";
6+
setup-ocamlc.byte-build-env;
7+
}{
8+
ocamlc.byte;
9+
program = "-quiet -index -decls index_aliases.cmt";
10+
output = "out_objinfo";
11+
check-ocamlc.byte-output;
12+
ocamlobjinfo;
13+
check-program-output;
14+
}
1515
*)
1616

1717

testsuite/tests/shape-index/index_bindingops.ml

Lines changed: 10 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,14 @@
11
(* TEST
2-
3-
flags = "-bin-annot -bin-annot-occurrences"
4-
compile_only = "true"
5-
* setup-ocamlc.byte-build-env
6-
all_modules = "index_bindingops.ml"
7-
** ocamlc.byte
8-
*** check-ocamlc.byte-output
9-
10-
program = "-quiet -index -decls index_bindingops.cmt"
11-
output = "out_objinfo"
12-
**** ocamlobjinfo
13-
14-
***** check-program-output
2+
flags = "-bin-annot -bin-annot-occurrences";
3+
compile_only = "true";
4+
all_modules = "index_bindingops.ml";
5+
setup-ocamlc.byte-build-env;
6+
ocamlc.byte;
7+
program = "-quiet -index -decls index_bindingops.cmt";
8+
output = "out_objinfo";
9+
check-ocamlc.byte-output;
10+
ocamlobjinfo;
11+
check-program-output;
1512
*)
1613

1714
let (let+) x f = Option.map f x
Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,47 +1,47 @@
11
Indexed shapes:
22
Resolved: Index_bindingops.3 :
3-
(and+) (File "index_bindingops.ml", line 30, characters 8-14)
3+
(and+) (File "index_bindingops.ml", line 27, characters 8-14)
44
Resolved: Index_bindingops.0 :
5-
(let+) (File "index_bindingops.ml", line 29, characters 8-14)
5+
(let+) (File "index_bindingops.ml", line 26, characters 8-14)
66
Resolved: Index_bindingops.11 :
7-
man (File "index_bindingops.ml", line 27, characters 14-17)
7+
man (File "index_bindingops.ml", line 24, characters 14-17)
88
Resolved: Index_bindingops.10 :
9-
bar (File "index_bindingops.ml", line 27, characters 8-11)
9+
bar (File "index_bindingops.ml", line 24, characters 8-11)
1010
Resolved: Index_bindingops.9 :
11-
foo (File "index_bindingops.ml", line 27, characters 2-5)
11+
foo (File "index_bindingops.ml", line 24, characters 2-5)
1212
Unresolved: CU Stdlib . "+"[value] :
13-
(+) (File "index_bindingops.ml", line 27, characters 6-7)
13+
(+) (File "index_bindingops.ml", line 24, characters 6-7)
1414
Unresolved: CU Stdlib . "-"[value] :
15-
(-) (File "index_bindingops.ml", line 27, characters 12-13)
15+
(-) (File "index_bindingops.ml", line 24, characters 12-13)
1616
Resolved: Index_bindingops.3 :
17-
(and+) (File "index_bindingops.ml", line 26, characters 2-6)
17+
(and+) (File "index_bindingops.ml", line 23, characters 2-6)
1818
Resolved: Index_bindingops.3 :
19-
(and+) (File "index_bindingops.ml", line 25, characters 2-6)
19+
(and+) (File "index_bindingops.ml", line 22, characters 2-6)
2020
Resolved: Index_bindingops.0 :
21-
(let+) (File "index_bindingops.ml", line 24, characters 2-6)
21+
(let+) (File "index_bindingops.ml", line 21, characters 2-6)
2222
Resolved: Index_bindingops.5 :
23-
y (File "index_bindingops.ml", line 21, characters 31-32)
23+
y (File "index_bindingops.ml", line 18, characters 31-32)
2424
Resolved: Index_bindingops.7 :
25-
y (File "index_bindingops.ml", line 21, characters 27-28)
25+
y (File "index_bindingops.ml", line 18, characters 27-28)
2626
Resolved: Index_bindingops.6 :
27-
x (File "index_bindingops.ml", line 21, characters 24-25)
27+
x (File "index_bindingops.ml", line 18, characters 24-25)
2828
Unresolved: CU Stdlib . "Option"[module] . "map"[value] :
29-
Option.map (File "index_bindingops.ml", line 21, characters 2-12)
29+
Option.map (File "index_bindingops.ml", line 18, characters 2-12)
3030
Resolved: Index_bindingops.4 :
31-
x (File "index_bindingops.ml", line 20, characters 14-15)
31+
x (File "index_bindingops.ml", line 17, characters 14-15)
3232
Unresolved: CU Stdlib . "Option"[module] . "bind"[value] :
33-
Option.bind (File "index_bindingops.ml", line 20, characters 2-13)
33+
Option.bind (File "index_bindingops.ml", line 17, characters 2-13)
3434
Resolved: Index_bindingops.1 :
35-
x (File "index_bindingops.ml", line 17, characters 30-31)
35+
x (File "index_bindingops.ml", line 14, characters 30-31)
3636
Resolved: Index_bindingops.2 :
37-
f (File "index_bindingops.ml", line 17, characters 28-29)
37+
f (File "index_bindingops.ml", line 14, characters 28-29)
3838
Unresolved: CU Stdlib . "Option"[module] . "map"[value] :
39-
Option.map (File "index_bindingops.ml", line 17, characters 17-27)
39+
Option.map (File "index_bindingops.ml", line 14, characters 17-27)
4040

4141
Uid of decls:
4242
Index_bindingops.8:
43-
minus_three (File "index_bindingops.ml", line 23, characters 4-15)
43+
minus_three (File "index_bindingops.ml", line 20, characters 4-15)
4444
Index_bindingops.0:
45-
let+ (File "index_bindingops.ml", line 17, characters 4-10)
45+
let+ (File "index_bindingops.ml", line 14, characters 4-10)
4646
Index_bindingops.3:
47-
and+ (File "index_bindingops.ml", line 19, characters 4-10)
47+
and+ (File "index_bindingops.ml", line 16, characters 4-10)

testsuite/tests/shape-index/index_constrs.ml

Lines changed: 11 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,15 @@
11
(* TEST
2-
3-
flags = "-bin-annot -bin-annot-occurrences"
4-
compile_only = "true"
5-
readonly_files = "index_constrs.ml"
6-
* setup-ocamlc.byte-build-env
7-
all_modules = "index_constrs.ml"
8-
** ocamlc.byte
9-
*** check-ocamlc.byte-output
10-
11-
program = "-quiet -index -decls index_constrs.cmt"
12-
output = "out_objinfo"
13-
**** ocamlobjinfo
14-
15-
***** check-program-output
2+
flags = "-bin-annot -bin-annot-occurrences";
3+
compile_only = "true";
4+
readonly_files = "index_constrs.ml";
5+
all_modules = "index_constrs.ml";
6+
setup-ocamlc.byte-build-env;
7+
ocamlc.byte;
8+
program = "-quiet -index -decls index_constrs.cmt";
9+
output = "out_objinfo";
10+
check-ocamlc.byte-output;
11+
ocamlobjinfo;
12+
check-program-output;
1613
*)
1714

1815
exception E
Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,26 @@
11
Indexed shapes:
22
Resolved: Index_constrs.1 :
3-
M.F (File "index_constrs.ml", line 32, characters 32-35)
3+
M.F (File "index_constrs.ml", line 29, characters 32-35)
44
Resolved: Index_constrs.0 :
5-
E (File "index_constrs.ml", line 29, characters 14-15)
5+
E (File "index_constrs.ml", line 26, characters 14-15)
66
Resolved: Index_constrs.4 :
7-
E (File "index_constrs.ml", line 28, characters 4-5)
7+
E (File "index_constrs.ml", line 25, characters 4-5)
88
Resolved: Index_constrs.7 :
9-
x (File "index_constrs.ml", line 27, characters 16-17)
9+
x (File "index_constrs.ml", line 24, characters 16-17)
1010
Resolved: Index_constrs.0 :
11-
E (File "index_constrs.ml", line 26, characters 15-16)
11+
E (File "index_constrs.ml", line 23, characters 15-16)
1212
Unresolved: CU Stdlib . "raise"[value] :
13-
raise (File "index_constrs.ml", line 26, characters 9-14)
13+
raise (File "index_constrs.ml", line 23, characters 9-14)
1414
Resolved: Index_constrs.4 :
15-
E (File "index_constrs.ml", line 25, characters 9-10)
15+
E (File "index_constrs.ml", line 22, characters 9-10)
1616
Resolved: Index_constrs.0 :
17-
E (File "index_constrs.ml", line 20, characters 16-17)
17+
E (File "index_constrs.ml", line 17, characters 16-17)
1818

1919
Uid of decls:
20-
Index_constrs.6: f (File "index_constrs.ml", line 27, characters 4-5)
21-
Index_constrs.5: x_ (File "index_constrs.ml", line 25, characters 4-6)
22-
Index_constrs.0: E (File "index_constrs.ml", line 18, characters 10-11)
23-
Index_constrs.2: M (File "index_constrs.ml", line 19, characters 7-8)
24-
Index_constrs.1: F (File "index_constrs.ml", line 20, characters 12-13)
25-
Index_constrs.3: t (File "index_constrs.ml", line 23, characters 5-6)
26-
Index_constrs.4: E (File "index_constrs.ml", line 23, characters 9-10)
20+
Index_constrs.6: f (File "index_constrs.ml", line 24, characters 4-5)
21+
Index_constrs.5: x_ (File "index_constrs.ml", line 22, characters 4-6)
22+
Index_constrs.0: E (File "index_constrs.ml", line 15, characters 10-11)
23+
Index_constrs.2: M (File "index_constrs.ml", line 16, characters 7-8)
24+
Index_constrs.1: F (File "index_constrs.ml", line 17, characters 12-13)
25+
Index_constrs.3: t (File "index_constrs.ml", line 20, characters 5-6)
26+
Index_constrs.4: E (File "index_constrs.ml", line 20, characters 9-10)

testsuite/tests/shape-index/index_constrs_records.ml

Lines changed: 11 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,15 @@
11
(* TEST
2-
3-
flags = "-bin-annot -bin-annot-occurrences"
4-
compile_only = "true"
5-
readonly_files = "index_constrs_records.ml"
6-
* setup-ocamlc.byte-build-env
7-
all_modules = "index_constrs_records.ml"
8-
** ocamlc.byte
9-
*** check-ocamlc.byte-output
10-
11-
program = "-quiet -index -decls index_constrs_records.cmt"
12-
output = "out_objinfo"
13-
**** ocamlobjinfo
14-
15-
***** check-program-output
2+
flags = "-bin-annot -bin-annot-occurrences";
3+
compile_only = "true";
4+
readonly_files = "index_constrs_records.ml";
5+
all_modules = "index_constrs_records.ml";
6+
setup-ocamlc.byte-build-env;
7+
ocamlc.byte;
8+
program = "-quiet -index -decls index_constrs_records.cmt";
9+
output = "out_objinfo";
10+
check-ocamlc.byte-output;
11+
ocamlobjinfo;
12+
check-program-output;
1613
*)
1714
type l = { lbl : int }
1815
module M : sig
Lines changed: 45 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -1,93 +1,93 @@
11
Indexed shapes:
22
Resolved: Index_constrs_records.34 :
3-
l_exn (File "index_constrs_records.ml", line 43, characters 21-26)
3+
l_exn (File "index_constrs_records.ml", line 40, characters 21-26)
44
Resolved: Index_constrs_records.30 :
5-
l_exn (File "index_constrs_records.ml", line 43, characters 10-15)
5+
l_exn (File "index_constrs_records.ml", line 40, characters 10-15)
66
Resolved: Index_constrs_records.31 :
7-
Exn (File "index_constrs_records.ml", line 43, characters 4-7)
7+
Exn (File "index_constrs_records.ml", line 40, characters 4-7)
88
Resolved: Index_constrs_records.33 :
9-
e (File "index_constrs_records.ml", line 42, characters 14-15)
9+
e (File "index_constrs_records.ml", line 39, characters 14-15)
1010
Resolved: Index_constrs_records.30 :
11-
l_exn (File "index_constrs_records.ml", line 41, characters 14-19)
11+
l_exn (File "index_constrs_records.ml", line 38, characters 14-19)
1212
Resolved: Index_constrs_records.31 :
13-
Exn (File "index_constrs_records.ml", line 41, characters 8-11)
13+
Exn (File "index_constrs_records.ml", line 38, characters 8-11)
1414
Resolved: Index_constrs_records.29 :
15-
l_ext (File "index_constrs_records.ml", line 36, characters 21-26)
15+
l_ext (File "index_constrs_records.ml", line 33, characters 21-26)
1616
Resolved: Index_constrs_records.24 :
17-
l_ext (File "index_constrs_records.ml", line 36, characters 10-15)
17+
l_ext (File "index_constrs_records.ml", line 33, characters 10-15)
1818
Resolved: Index_constrs_records.25 :
19-
Ext (File "index_constrs_records.ml", line 36, characters 4-7)
19+
Ext (File "index_constrs_records.ml", line 33, characters 4-7)
2020
Resolved: Index_constrs_records.28 :
21-
x (File "index_constrs_records.ml", line 35, characters 22-23)
21+
x (File "index_constrs_records.ml", line 32, characters 22-23)
2222
Resolved: Index_constrs_records.23 :
23-
u (File "index_constrs_records.ml", line 35, characters 11-12)
23+
u (File "index_constrs_records.ml", line 32, characters 11-12)
2424
Resolved: Index_constrs_records.23 :
25-
u (File "index_constrs_records.ml", line 33, characters 5-6)
25+
u (File "index_constrs_records.ml", line 30, characters 5-6)
2626
Resolved: Index_constrs_records.22 :
27-
l (File "index_constrs_records.ml", line 30, characters 47-48)
27+
l (File "index_constrs_records.ml", line 27, characters 47-48)
2828
Resolved: Index_constrs_records.1 :
29-
lbl (File "index_constrs_records.ml", line 30, characters 49-52)
29+
lbl (File "index_constrs_records.ml", line 27, characters 49-52)
3030
Resolved: Index_constrs_records.21 :
31-
lbl (File "index_constrs_records.ml", line 30, characters 41-44)
31+
lbl (File "index_constrs_records.ml", line 27, characters 41-44)
3232
Resolved: Index_constrs_records.20 :
33-
l_c (File "index_constrs_records.ml", line 30, characters 35-38)
33+
l_c (File "index_constrs_records.ml", line 27, characters 35-38)
3434
Unresolved: CU Stdlib . "+"[value] :
35-
(+) (File "index_constrs_records.ml", line 30, characters 39-40)
35+
(+) (File "index_constrs_records.ml", line 27, characters 39-40)
3636
Unresolved: CU Stdlib . "+"[value] :
37-
(+) (File "index_constrs_records.ml", line 30, characters 45-46)
37+
(+) (File "index_constrs_records.ml", line 27, characters 45-46)
3838
Resolved: Index_constrs_records.1 :
39-
lbl (File "index_constrs_records.ml", line 30, characters 21-24)
39+
lbl (File "index_constrs_records.ml", line 27, characters 21-24)
4040
Resolved: Index_constrs_records.3 :
41-
l_c (File "index_constrs_records.ml", line 30, characters 11-14)
41+
l_c (File "index_constrs_records.ml", line 27, characters 11-14)
4242
Resolved: Index_constrs_records.4 :
43-
A (File "index_constrs_records.ml", line 30, characters 7-8)
43+
A (File "index_constrs_records.ml", line 27, characters 7-8)
4444
Resolved: Index_constrs_records.3 :
45-
l_c (File "index_constrs_records.ml", line 29, characters 12-15)
45+
l_c (File "index_constrs_records.ml", line 26, characters 12-15)
4646
Resolved: Index_constrs_records.4 :
47-
A (File "index_constrs_records.ml", line 29, characters 8-9)
47+
A (File "index_constrs_records.ml", line 26, characters 8-9)
4848
Resolved: Index_constrs_records.17 :
49-
M (File "index_constrs_records.ml", line 27, characters 5-6)
49+
M (File "index_constrs_records.ml", line 24, characters 5-6)
5050
Resolved: Index_constrs_records.3 :
51-
l_c (File "index_constrs_records.ml", line 25, characters 14-17)
51+
l_c (File "index_constrs_records.ml", line 22, characters 14-17)
5252
Resolved: Index_constrs_records.4 :
53-
M.A (File "index_constrs_records.ml", line 25, characters 8-11)
53+
M.A (File "index_constrs_records.ml", line 22, characters 8-11)
5454
Resolved: Index_constrs_records.3 :
55-
l_c (File "index_constrs_records.ml", line 22, characters 14-17)
55+
l_c (File "index_constrs_records.ml", line 19, characters 14-17)
5656
Resolved: Index_constrs_records.4 :
57-
A (File "index_constrs_records.ml", line 22, characters 10-11)
57+
A (File "index_constrs_records.ml", line 19, characters 10-11)
5858

5959
Uid of decls:
6060
Index_constrs_records.19:
61-
f (File "index_constrs_records.ml", line 30, characters 4-5)
61+
f (File "index_constrs_records.ml", line 27, characters 4-5)
6262
Index_constrs_records.4:
63-
A (File "index_constrs_records.ml", line 21, characters 11-12)
63+
A (File "index_constrs_records.ml", line 18, characters 11-12)
6464
Index_constrs_records.33:
65-
e (File "index_constrs_records.ml", line 41, characters 4-5)
65+
e (File "index_constrs_records.ml", line 38, characters 4-5)
6666
Index_constrs_records.10:
67-
l_c (File "index_constrs_records.ml", line 19, characters 18-21)
67+
l_c (File "index_constrs_records.ml", line 16, characters 18-21)
6868
Index_constrs_records.2:
69-
t (File "index_constrs_records.ml", line 21, characters 7-8)
69+
t (File "index_constrs_records.ml", line 18, characters 7-8)
7070
Index_constrs_records.25:
71-
Ext (File "index_constrs_records.ml", line 33, characters 10-13)
71+
Ext (File "index_constrs_records.ml", line 30, characters 10-13)
7272
Index_constrs_records.24:
73-
l_ext (File "index_constrs_records.ml", line 33, characters 19-24)
73+
l_ext (File "index_constrs_records.ml", line 30, characters 19-24)
7474
Index_constrs_records.3:
75-
l_c (File "index_constrs_records.ml", line 21, characters 18-21)
75+
l_c (File "index_constrs_records.ml", line 18, characters 18-21)
7676
Index_constrs_records.30:
77-
l_exn (File "index_constrs_records.ml", line 39, characters 18-23)
77+
l_exn (File "index_constrs_records.ml", line 36, characters 18-23)
7878
Index_constrs_records.17:
79-
M (File "index_constrs_records.ml", line 18, characters 7-8)
79+
M (File "index_constrs_records.ml", line 15, characters 7-8)
8080
Index_constrs_records.31:
81-
Exn (File "index_constrs_records.ml", line 39, characters 10-13)
81+
Exn (File "index_constrs_records.ml", line 36, characters 10-13)
8282
Index_constrs_records.11:
83-
A (File "index_constrs_records.ml", line 19, characters 11-12)
83+
A (File "index_constrs_records.ml", line 16, characters 11-12)
8484
Index_constrs_records.27:
85-
f (File "index_constrs_records.ml", line 35, characters 4-5)
85+
f (File "index_constrs_records.ml", line 32, characters 4-5)
8686
Index_constrs_records.9:
87-
t (File "index_constrs_records.ml", line 19, characters 7-8)
87+
t (File "index_constrs_records.ml", line 16, characters 7-8)
8888
Index_constrs_records.0:
89-
l (File "index_constrs_records.ml", line 17, characters 5-6)
89+
l (File "index_constrs_records.ml", line 14, characters 5-6)
9090
Index_constrs_records.23:
91-
u (File "index_constrs_records.ml", line 32, characters 5-6)
91+
u (File "index_constrs_records.ml", line 29, characters 5-6)
9292
Index_constrs_records.1:
93-
lbl (File "index_constrs_records.ml", line 17, characters 11-14)
93+
lbl (File "index_constrs_records.ml", line 14, characters 11-14)

0 commit comments

Comments
 (0)