Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion compiler/ml/ast_mapper_to0.ml
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,9 @@ module T = struct
| Ptyp_arrow {arg; ret; arity} -> (
let lbl = Asttypes.to_noloc arg.lbl in
let typ0 =
arrow ~loc ~attrs lbl (sub.typ sub arg.typ) (sub.typ sub ret)
arrow ~loc
~attrs:(attrs @ sub.attributes sub arg.attrs)
lbl (sub.typ sub arg.typ) (sub.typ sub ret)
in
match arity with
| None -> typ0
Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1 @@
type fn = (~foo: string) => int
type fn = (@as("something") ~foo: string) => int
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This commit illustrates the difference.
This should fix the original issue, but needs testing just in case.

Loading