Open shashi opened 4 years ago
Better yet, it would be nice if we could give precise diagnostics that say why code is untyped and how to fix it. This is still a bit abstract for me though; I'm hoping to see some failure cases from from users, which should help us explain mjolnir's failure cases in user terms.
There aren't that many sources of unions in standard Julia code. Iteration is one case that we should definitely support. Try/catch and recursive types are a source of Any
s in normal Julia inference which we don't currently support; potentially we could make those things inferable though, e.g. if we have effect inference.
Tracing may not be possible in situations where there is no unique next method to pick to trace. But this situation should occur way less with Mjolnir as opposed to using the standard Julia type inference as can be seen in this example
But should document when exactly it won't work, and provide reasonable suggestions to avoid those cases.