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
The problem here is the promote_type -> promote_result -> promote_type recursion. In many cases, one of promote_rule(T,S) and promote_rule(S, T) returns Union{} which hits a dedicated promote_type method in the recursion. But
The easiest fix would be to add a specialized promote_rule method to avoid this. But I wonder how many other combinations are equally problematic. Making inference's recursion detection more liberal (like it accidentally was before) seems not great, as this is actually a case where limiting is required to ensure termination.
There seems to be the following regression in Julia v1.7.0-rc2 (compared to Julia v1.6.3):
(on Julia v1.7.0-rc2)
On the other hand,
Base.promote_type(Bool, Irrational{:π})
seems to predict the type properly on both versions of Julia.(on Julia v1.7.0-rc2)
The text was updated successfully, but these errors were encountered: