4 ms·
In julia we switched to making method ambiguities a runtime error because you often end up with situations where even though there are ambiguous methods, you do
by KenoFischer 10y ago
In julia we switched to making method ambiguities a runtime error because you often end up with situations where even though there are ambiguous methods, you don't ever really want to call them (because they don't make much sense semantically or because they came from different packages, etc). Stanza looks a little more static than julia in this regard, so perhaps they do want to make it a compile-time error (or at least make calling it a compile-time error if types are declared).
- patricksli 10y agoWe are planning to add a static method ambiguity check in Stanza. There are just some theoretical hurdles to solve in order to detect them properly in the presence of parametric types. That's been recently solved (though not by us) so we'll be implementing their solution soon.
- micro2588 10y agoHi Patrick, can you point to a paper / resource that describes this recent work?
- patricksli 10y agoSure. The paper is called "Type Checking Modular Multiple Dispatch with Parametric Polymorphism and Multiple Inheritance" by Allen, Hilburn, et al.