-
Notifications
You must be signed in to change notification settings - Fork 53
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix Uncurried Fragment module signature #297
base: master
Are you sure you want to change the base?
Fix Uncurried Fragment module signature #297
Conversation
src/ppx/output_module.ml
Outdated
wrap_as_uncurried_fn [%stri let parse (value : Raw.t) = [%e parse_fn]]; | ||
wrap_as_uncurried_fn | ||
[%stri | ||
let parse = (fun value -> [%e parse_fn] : Raw.t -> [%t type_name])]; | ||
wrap_as_uncurried_fn | ||
[%stri | ||
let serialize = | ||
(fun value -> [%e serialize_fn] : [%t type_name] -> Raw.t)]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've fiddled with this a few times and all the options seem to generate a lot of changes in the printed output.
generate_operation_implementation
doesn't include any type annotations here, would that be preferable for this as well?
1a08f56
to
24dc054
Compare
resolves teamwalnut#296 the module signature was not wrapped, and the implementation was wrapped in another fun that prevented the match in wrap_as_uncurried_fn from working as intended I also fixed a warning 53 with the @@tailcall attribute I was getting for ocaml 5.1.1, maybe I ended up with different versions of something? re-run tests
24dc054
to
a27bf33
Compare
Are there other test projects I can try this build against? |
resolves #296
the module signature was not wrapped, and the implementation was wrapped in another fun that prevented the match in wrap_as_uncurried_fn from working as intended
I also fixed a warning 53 with the @@tailcall attribute I was getting for ocaml 5.1.1, maybe I ended up with different versions of something?