-
Notifications
You must be signed in to change notification settings - Fork 15
merlin document support for PPXs #167
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
Conversation
liam923
left a comment
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.
Overall this looks good! I think the main things are just adding more tests and moving some more of the logic into ppx_document.ml.
liam923
left a comment
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.
Awesome, pretty much just one nit left.
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.
Awesome, thanks for these changes! Feel free to merge (I think you have permission to hit the merge button?). Sidenote: in oxcaml/merlin we tend to prefer "Squash and merge" over "Create a merge commit". I think this makes the git history a lot more managable. The exception to this is when we're merging changes from upstream, in which case this can confuse git and create future merges harder.
* initial working with tests * temp update * temp * major refactors, add support for .mli files * refactoring and cleanup * move all logic into override_document.ml; cleanup code; add logging * add many more tests; handle edge cases * revert std.ml changes * improve comments * update more comments * suggested changes * test nested ppx * document payload test * some more tests * resolve final comments * add test on floating attribute * add test for attribute in an extension's payload
* merlin document support for PPXs (#167) * initial working with tests * temp update * temp * major refactors, add support for .mli files * refactoring and cleanup * move all logic into override_document.ml; cleanup code; add logging * add many more tests; handle edge cases * revert std.ml changes * improve comments * update more comments * suggested changes * test nested ppx * document payload test * some more tests * resolve final comments * add test on floating attribute * add test for attribute in an extension's payload * Fix function syntax * working parsing of new merlin.document structure * fix document tests with new merlin.document structure * replicate merlin.document tests for merlin.locate * generalize comments, code for all overrides * delete duplicate files from merge conflict * add test overriding locate of a non-PPX * add test on overriding default behavior of document * format * combine document and locate tests into single file * adjust for new attribute structure * update comment documenting expected attribute structure * fix typo * remove named parameter * merlin locate outputs absolute paths using source_root --------- Co-authored-by: Liam Stevenson <lstevenson@janestreet.com>
* merlin document support for PPXs (#167) * initial working with tests * temp update * temp * major refactors, add support for .mli files * refactoring and cleanup * move all logic into override_document.ml; cleanup code; add logging * add many more tests; handle edge cases * revert std.ml changes * improve comments * update more comments * suggested changes * test nested ppx * document payload test * some more tests * resolve final comments * add test on floating attribute * add test for attribute in an extension's payload * Fix function syntax * merlin overrides: merlin locate support for PPXs (#171) * merlin document support for PPXs (#167) * initial working with tests * temp update * temp * major refactors, add support for .mli files * refactoring and cleanup * move all logic into override_document.ml; cleanup code; add logging * add many more tests; handle edge cases * revert std.ml changes * improve comments * update more comments * suggested changes * test nested ppx * document payload test * some more tests * resolve final comments * add test on floating attribute * add test for attribute in an extension's payload * Fix function syntax * working parsing of new merlin.document structure * fix document tests with new merlin.document structure * replicate merlin.document tests for merlin.locate * generalize comments, code for all overrides * delete duplicate files from merge conflict * add test overriding locate of a non-PPX * add test on overriding default behavior of document * format * combine document and locate tests into single file * adjust for new attribute structure * update comment documenting expected attribute structure * fix typo * remove named parameter * merlin locate outputs absolute paths using source_root --------- Co-authored-by: Liam Stevenson <lstevenson@janestreet.com> * merlin overrides use interval tree instead of list (#173) * interval tree interface * interval tree implementation and basic test * use array for construction, add more tests * add and update comments * fix error messages, validate inputs * use list instead of array, add tests, add comments * integrate into overrides.ml * add test for empty tree * resolve requested changes * add test for zero-width interval * undo test reformat * update outdated comment * update another oudated comment * update comment * Cache overrides interval trees using Phase_cache (#176) * implementation but failing tests * working overrides caching with tests * add USE_PPX_CACHE, add all cache entries to tests * update comments * use Option.map * move comment * fix overrides caching mechanism, functorize caches, add cache invalidation test * add comments, rename * cleanup test output, and resolve other comments * remove unnecessary sed commands from tests * add commentsg --------- Co-authored-by: Max Wang <orangemax888@gmail.com>
Builds upon features written in our internal codebase.
[@@@merlin.document]attributeTesting
Adds unit tests for
.mland.mlifiles