Antonio Nuno Monteiro

Results 226 comments of Antonio Nuno Monteiro

> the problematic error message is emitted by the ppxlib driver, not the compiler later on, and my fix has an effect because the driver calls the compiler error-printing logic...

After reflecting for a bit and considering other use cases, I think I found one that justifies this change: - code that emits alerts via `Ocaml_common.Location.prerr_alert` in PPXes won't have...

This is not necessary for Melange if it's fixed in ppxlib, apart from the newly broken usecase that all OCaml programs will also face: from https://github.com/ocaml/ocaml/pull/12991#issuecomment-1989708009 > code that emits...

They’re different printers. In that case the error printer would come from ppxlib (which now has this fix), but the alert printer would come from `Ocaml_common.Location` which comes from the...

> They are the same printers? The `Astlib` module on the ppxlib side is including the compiler's `Location` module, and updating the shared `Location.input_lexbuf`. Got it, thanks. This seems to...

Actually, revisiting this again, it doesn't seem to be a Melange bug at all. I prepared a reproduction in this repository: https://github.com/anmonteiro/no-source-quotation-repro If you run the instructions in the README...

OK, so I changed my mind again: there _is_ a bug, but it's not in OCaml. Turns out, I believe the ppxlib fix is incomplete. When reading binary AST, we...

I suppose this could be specific to arm64 macs? here's a failing build on arm64: https://github.com/melange-re/melange/actions/runs/8240717242/job/22536631215?pr=1081

> what’s the reason for building the bootstrap target? I'm not sure. This is the build phase for the OCaml compiler in nixpkgs: https://github.com/NixOS/nixpkgs/blob/002f8266a0caeb9a4108dcb6c8107eeaff280247/pkgs/development/compilers/ocaml/Makefile.nixpkgs#L13-L16