Skip to content

Commit f9633a1

Browse files
committed
Support inline records
1 parent 1bad290 commit f9633a1

6 files changed

+12
-12
lines changed

jscomp/core/js_dump.ml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -774,7 +774,7 @@ and expression_desc cxt ~(level : int) f x : cxt =
774774
if p.num_nonconst = 1 then tails
775775
else
776776
( Js_op.Lit L.tag,
777-
if !Js_config.debug then tag else { tag with comment = Some p.name }
777+
E.str p.name
778778
)
779779
:: tails
780780
in

jscomp/test/inline_record_test.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,13 +17,13 @@ function eq(loc, x, y) {
1717
}
1818

1919
var v = {
20-
TAG: /* A0 */0,
20+
TAG: "A0",
2121
lbl: 3,
2222
more: /* [] */0
2323
};
2424

2525
var v1 = {
26-
TAG: /* A1 */1,
26+
TAG: "A1",
2727
more: {
2828
hd: 1,
2929
tl: {
@@ -88,14 +88,14 @@ function ff(x) {
8888
}
8989

9090
var v4 = {
91-
TAG: /* A0 */0,
91+
TAG: "A0",
9292
x: 0,
9393
y: 0,
9494
z: 0
9595
};
9696

9797
var v5 = {
98-
TAG: /* A1 */1,
98+
TAG: "A1",
9999
z: 0
100100
};
101101

jscomp/test/large_record_duplication_test.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ function f1(x) {
102102
eq("File \"large_record_duplication_test.ml\", line 140, characters 6-13", get_x0(f1(v1)), 1);
103103

104104
var v2 = {
105-
TAG: /* A0 */0,
105+
TAG: "A0",
106106
x0: 9,
107107
x1: 9,
108108
x2: 9,

jscomp/test/rec_value_test.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -297,7 +297,7 @@ function ptl(l) {
297297
var y00 = {};
298298

299299
Caml_obj.update_dummy(y00, {
300-
TAG: /* C1 */1,
300+
TAG: "C1",
301301
hd: 1,
302302
tail: y00
303303
});

jscomp/test/record_extension_test.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ function f2_with(x) {
4848
return x;
4949
} else {
5050
return {
51-
TAG: /* C */0,
51+
TAG: "C",
5252
x: 0,
5353
y: x.y
5454
};

jscomp/test/record_regression.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -61,28 +61,28 @@ function setAA(ao) {
6161
}
6262

6363
var ir0 = {
64-
TAG: /* V0 */0,
64+
TAG: "V0",
6565
x0: "v0",
6666
x3: 3
6767
};
6868

6969
var ir1 = {
70-
TAG: /* V0 */0,
70+
TAG: "V0",
7171
x0: "v0",
7272
x1: "v1",
7373
x3: 3
7474
};
7575

7676
var ir2 = {
77-
TAG: /* V0 */0,
77+
TAG: "V0",
7878
x0: "v0",
7979
x1: "v1",
8080
x2: 2,
8181
x3: 3
8282
};
8383

8484
var ir3 = {
85-
TAG: /* V1 */1,
85+
TAG: "V1",
8686
y0: "v0",
8787
y1: 1
8888
};

0 commit comments

Comments
 (0)