Skip to content

Commit 8ad9e03

Browse files
committed
remove rec from recursive component
1 parent b4d70de commit 8ad9e03

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

res_syntax/src/reactjs_jsx_v4.ml

+2-1
Original file line numberDiff line numberDiff line change
@@ -1254,7 +1254,8 @@ let transformStructureItem ~config mapper item =
12541254
List.fold_right otherStructures structuresAndBinding ([], [], [])
12551255
in
12561256
types
1257-
@ [{pstr_loc; pstr_desc = Pstr_value (recFlag, bindings)}]
1257+
(* No need to be Recursive as internal representation is called *)
1258+
@ [{pstr_loc; pstr_desc = Pstr_value (Nonrecursive, bindings)}]
12581259
@
12591260
match newBindings with
12601261
| [] -> []

res_syntax/tests/ppx/react/expected/v4.res.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ module EUncurried = {
4949
module Rec = {
5050
type props = {}
5151

52-
let rec make = {
52+
let make = {
5353
@merlin.focus
5454
let rec \"make$Internal" = (_: props) => {
5555
make(({}: props))

0 commit comments

Comments
 (0)