-
Notifications
You must be signed in to change notification settings - Fork 90
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
Make ppx deriving compatible with preprocessor type ppxlib extensions #245
Merged
kit-ty-kate
merged 1 commit into
ocaml-ppx:master
from
kit-ty-kate:ppxlib-no-preprocessor
Nov 25, 2020
Merged
Make ppx deriving compatible with preprocessor type ppxlib extensions #245
kit-ty-kate
merged 1 commit into
ocaml-ppx:master
from
kit-ty-kate:ppxlib-no-preprocessor
Nov 25, 2020
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ghost
approved these changes
Nov 25, 2020
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.
This change seems reasonable to me, and the new code makes more sense to me. You could probably find a combination of ppx rewriters where this is an issue, but you seem to have done enough testing here.
Thanks a lot for the review! Merging and tagging the release now 🎉 |
kit-ty-kate
added a commit
to kit-ty-kate/opam-repository
that referenced
this pull request
Nov 25, 2020
CHANGES: * Update to ppxlib 0.20.0 ocaml-ppx/ppx_deriving#237 ocaml-ppx/ppx_deriving#239 ocaml-ppx/ppx_deriving#243 ocaml-ppx/ppx_deriving#245 (Kate Deplaix, Jérémie Dimino, Thierry Martinez, Gabriel Scherer) * Upgrade testsuite from ounit to ounit2 ocaml-ppx/ppx_deriving#241 (Kate Deplaix) * (almost) use the set of standard flags from dune ocaml-ppx/ppx_deriving#246 (Kate Deplaix)
kit-ty-kate
added a commit
to kit-ty-kate/opam-repository
that referenced
this pull request
Nov 25, 2020
CHANGES: * Update to ppxlib 0.20.0 ocaml-ppx/ppx_deriving#237 ocaml-ppx/ppx_deriving#239 ocaml-ppx/ppx_deriving#243 ocaml-ppx/ppx_deriving#245 (Kate Deplaix, Jérémie Dimino, Thierry Martinez, Gabriel Scherer) * Upgrade testsuite from ounit to ounit2 ocaml-ppx/ppx_deriving#241 (Kate Deplaix) * (almost) use the set of standard flags from dune ocaml-ppx/ppx_deriving#246 (Kate Deplaix)
kit-ty-kate
added a commit
to kit-ty-kate/opam-repository
that referenced
this pull request
Nov 25, 2020
CHANGES: * Update to ppxlib 0.20.0 ocaml-ppx/ppx_deriving#237 ocaml-ppx/ppx_deriving#239 ocaml-ppx/ppx_deriving#243 ocaml-ppx/ppx_deriving#245 (Kate Deplaix, Jérémie Dimino, Thierry Martinez, Gabriel Scherer) * Upgrade testsuite from ounit to ounit2 ocaml-ppx/ppx_deriving#241 (Kate Deplaix) * (almost) use the set of standard flags from dune ocaml-ppx/ppx_deriving#246 (Kate Deplaix)
kit-ty-kate
added a commit
to kit-ty-kate/opam-repository
that referenced
this pull request
Nov 25, 2020
CHANGES: * Update to ppxlib 0.20.0 ocaml-ppx/ppx_deriving#237 ocaml-ppx/ppx_deriving#239 ocaml-ppx/ppx_deriving#243 ocaml-ppx/ppx_deriving#245 (Kate Deplaix, Jérémie Dimino, Thierry Martinez, Gabriel Scherer) * Upgrade testsuite from ounit to ounit2 ocaml-ppx/ppx_deriving#241 (Kate Deplaix) * (almost) use the set of standard flags from dune ocaml-ppx/ppx_deriving#246 (Kate Deplaix)
kit-ty-kate
added a commit
to kit-ty-kate/opam-repository
that referenced
this pull request
Nov 25, 2020
CHANGES: * Update to ppxlib 0.20.0 ocaml-ppx/ppx_deriving#237 ocaml-ppx/ppx_deriving#239 ocaml-ppx/ppx_deriving#243 ocaml-ppx/ppx_deriving#245 (Kate Deplaix, Jérémie Dimino, Thierry Martinez, Gabriel Scherer) * Upgrade testsuite from ounit to ounit2 ocaml-ppx/ppx_deriving#241 (Kate Deplaix) * (almost) use the set of standard flags from dune ocaml-ppx/ppx_deriving#246 (Kate Deplaix)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This is an attempt at fixing the last issue of ppx_deriving with ocaml-migrate-parsetree 2.0
The problem was that making ppx_deriving a "preprocesor type ppxlib extension", made it imcompatible with other "preprocessor type ppxlib extensions" such as
optcomp
and triggered errors in a handful of packages in opam-repository.From what I understand this was done to enforce an order between ppxs, and when mentioning this issue the ppxlib devs told me to use the
Ppxlib.Deriving
API. However, I'm no expert in eitherppxlib
norppx_deriving
and didn't manage to make it work in a reasonable time.Here I'm using the cheap method of simply stop caring about orders, I've ran a test on every opam packages for OCaml 4.11 with this change and no issue was found. So, to me, this seems safe to do so, since from what I understand, the previous code using OMP1 did not care about order either.
What do you think? @thierry-martinez @gasche