morloc-project / morloc

A typed, polyglot, functional language
GNU General Public License v3.0
195 stars 4 forks source link

Packers are not found for functions that are imported rather than declared #16

Closed arendsee closed 1 year ago

arendsee commented 1 year ago

This fails:

module tree (upgma)
import bio.algo (upgmaFromDist as upgma)

With error:

SerializationError: Cannot find constructor "RootedTree<$1,$2,$3>"<3> in packmap:
----- pacmaps -----

-------------------

The RootedTree constructor is defined by a module that bio.algo imports.

But this passes:

module tree (foo)
import bio.algo (upgmaFromDist as upgma)
foo x = upgma x
arendsee commented 1 year ago

Thanks for taking the time to submit this report! I really appreciate it! You are an awesome human being!

arendsee commented 1 year ago

A simpler case is:

module foo (keys)
import pybase (keys)

This fails to find the Map constructor.