File tree 2 files changed +5
-5
lines changed
tests/syntax_tests/data/parsing/errors
2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change 8
8
7 ┆ score: int
9
9
8 ┆ }
10
10
11
- An inline record type declaration is only allowed in a variant constructor's declaration
11
+ An inline record type declaration is only allowed in a variant constructor's declaration or nested inside of a record type declaration
12
12
13
13
14
14
Syntax error!
20
20
│ nder(props)
21
21
20 │
22
22
23
- An inline record type declaration is only allowed in a variant constructor's declaration
23
+ An inline record type declaration is only allowed in a variant constructor's declaration or nested inside of a record type declaration
24
24
25
25
type nonrec entity =
26
26
| Director
@@ -29,11 +29,11 @@ type nonrec entity =
29
29
reportCard: < passing: bool ;score: int > }
30
30
type user.address = {
31
31
street: string ;
32
- country: string }[@@inlineRecordDefinition ]
32
+ country: string }[@@res. inlineRecordDefinition ]
33
33
and user =
34
34
{
35
35
name: string ;
36
- address: ((user.address)[@inlineRecordReference ]) }
36
+ address: ((user.address)[@res. inlineRecordReference ]) }
37
37
let make
38
38
[arity:1](props :
39
39
< handleClick: Click.t -> unit (a:1) ;value: string > )
Original file line number Diff line number Diff line change 19
19
9 │ let f = (x: {a: int, b: int}) => ()
20
20
10 │
21
21
22
- An inline record type declaration is only allowed in a variant constructor's declaration
22
+ An inline record type declaration is only allowed in a variant constructor's declaration or nested inside of a record type declaration
23
23
24
24
type nonrec u = {
25
25
...: a ;
You can’t perform that action at this time.
0 commit comments