-
Notifications
You must be signed in to change notification settings - Fork 43
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
Are there size limits on the binary ast as produced by --dump-ast? #39
Comments
I think it's quite large, what error are you getting? |
The concrete error is
when compiling the branch in this PR. For context I'm using a ppx and cppo to generate [mono|di]morphic higher level functions (ex. Maybe this should be filed under dune but is there a way to have dune omit this flag and go the slower text route? I'm fine with special casing a custom pp'ing rule? |
The error doesn't look right, it should be something like My guess is that the generated AST is wrong, however when pretty printed, the printer prints something that ends up being valid OCaml code.
|
You were right, I was initially deceived into thinking that the ppx was correct because it worked for many other kinds and then started breaking with |
No problem. One way to make it easier to debug such errors would be to extend the invariants checks that are performed by the compiler to also check identifiers: https://github.com/ocaml/ocaml/blob/trunk/parsing/ast_invariants.mli |
Thanks again, that's super helpful. I did not know about them. |
I'm running to a weird bug that is resolved by removing that argument and compiling from the generated source.
The text was updated successfully, but these errors were encountered: