Skip to content
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

ppx_sexp_conv creates code triggering warning 40 #1187

Closed
frank-emrich opened this issue Oct 17, 2023 · 3 comments
Closed

ppx_sexp_conv creates code triggering warning 40 #1187

frank-emrich opened this issue Oct 17, 2023 · 3 comments

Comments

@frank-emrich
Copy link
Contributor

When using version 16.0 of the ppx_sexp_conv package, types annotated with [@@deriving sexp] may obtain sexp conversion functions whose body triggers warning 40, as seen in the following example:

File "lens/column.ml", lines 4-11, characters 0-23:
 4 | type t = {
 5 |   table : string;
 6 |   name : string;
 7 |   alias : string;
 8 |   typ : Type.t;
 9 |   present : bool;
10 | }
11 | [@@deriving show, sexp]
Warning 40 [name-out-of-scope]: Required was selected from type Sexplib0.Sexp_conv_record.Kind.t.
It is not visible in the current scope, and will not 
be selected if the type becomes unknown
@jamescheney
Copy link
Contributor

jamescheney commented Nov 14, 2023

Is this actually closed by #1188? I still seem to be seeing these warnings when rebuilding at least using ocaml 4.14

Never mind, I wasn't in the master branch when I saw this

@dhil
Copy link
Member

dhil commented Nov 14, 2023

Yes, it should be fixed by #1188.

@dhil dhil closed this as completed Nov 14, 2023
@frank-emrich
Copy link
Contributor Author

I didn't close this issue because I consider #1188 more of a workaround than a clean fix. But I don't see myself taking the time to look into the root cause and file an upstream bug with ppx_sexp_conv in the near future, so let's keep this closed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants