graphql-ppx icon indicating copy to clipboard operation
graphql-ppx copied to clipboard

Switch to impl/intf from preprocess_*

Open anmonteiro opened this issue 2 years ago • 2 comments

check the different ppxlib preprocessing phases: https://twitter.com/_anmonteiro/status/1644031054544789504

we want to run graphql_ppx in the "global transformations" phase, in order to allow graphql_ppx to be used with other PPXes that use the preprocess phase.

anmonteiro avatar Apr 06 '23 18:04 anmonteiro

With this change I'm seeing the following warning in every file with autogenerated graphql types:

Error (warning 61 [unboxable-type-in-prim-decl]): This primitive declaration uses type Raw.t, whose representation
may be either boxed or unboxed. Without an annotation to indicate
which representation is intended, the boxed representation has been
selected by default. This default choice may change in future
versions of the compiler, breaking the primitive implementation.
You should explicitly annotate the declaration of Raw.t
with [@@boxed] or [@@unboxed], so that its external interface
remains stable in the future.

Branch: https://github.com/jchavarri/graphql-ppx/commit/1663b3ff8baceac8901c3ced564ca2788a559a89

jakubrpawlowski avatar Dec 14 '23 05:12 jakubrpawlowski

It sounds unlikely that this branch would cause those warnings. Rather, they might be related to Melange, not the PPX.

anmonteiro avatar Dec 14 '23 13:12 anmonteiro