leostera / caramel

:candy: a functional language for building type-safe, scalable, and maintainable applications
https://caramel.run
Apache License 2.0
1.05k stars 25 forks source link

fix(compiler): do not prioritize using local functions over functions called through module qualifiers #66

Closed michallepicki closed 3 years ago

michallepicki commented 3 years ago

This is seemingly solving the issue because when the ocaml name is qualified, the erlang name also will be. I would need to understand the Texp_ident contents to see what to check in the typedtree before even translating the name to erlang instead to fix properly, but I was having a hard time debugging ocaml code.

Closes #58

michallepicki commented 3 years ago

@ostera I looked at this again and am I not sure if I can come up with anything better here. This seems to be solving this particualr issue though, so marking as ready for review :)