You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Union does not quite function as separate definitions. What's going on here is the following:
type is not a subtype of Union[type[Test], Test], because it is strictly more general than Test. In addition, Union[type[Test], Test] is not a subtype of type, because Test (which matches objects) is not a substype of type (which matches types):
Therefore, neither signature is more specific than the other, so Plum will not automatically narrow it down. If you input matches both signatures, Plum will throw an ambiguity error, as in the above example.
Hello!
With the following code:
a
is giving me anAmbiguousLookupError
:Shouldn't
Union
function the same as separate definitions?Thank you kindly for the help!
The text was updated successfully, but these errors were encountered: