julia
b167bc2a - fix #30394, an unsoundness in ml_matches (#30396)

Commit
7 years ago
fix #30394, an unsoundness in ml_matches (#30396) This fixes a corner case where a bug is caused, counter-intuitively, by an over-estimated intersection. We have method signatures A and B, with A<B (A is a strict subtype). We have a dispatch tuple X, where X<:B and !(X<:A). However, intersection returns X for intersect(X,A). Since there appears to be a match there and A<B, ml_matches skips the match with B. The fix just requires dispatch tuples to be a subtype of a signature in order to match at all.
Author
Parents
Loading