-
-
Notifications
You must be signed in to change notification settings - Fork 5.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Regression in inference with recursive methods #26224
Comments
|
Many thanks for the clarification Jameson, it makes sense. Just in case there is still some room for improvement here, I posted more info in the original discourse thread showing that the simple change |
(Ref: https://discourse.julialang.org/t/regression-in-v0-7-due-to-weird-inference-failure-for-function-with-lisp-y-recursion/9342)
For some reason the following code drives inference a bit crazy
If we call foo specifically in the following way, inference fails, and execution is slow (this can also be seen as a non-leaf inferred type of
foo
using@code_warntype
)The failure depends on the number and combination of
c
s andb
s.However, if we slightly change the last method definition to
inference recovers, and everything is elided
The problem occurs in current master, but did not happen approximately
one month ago(I didn't manage to find the precise commit, I'll keep trying [EDIT: I've gone back 4 months, and the problem was already there]). It also doesn't happen in v0.6.1. [EDIT: Neither in v0.6.2]The text was updated successfully, but these errors were encountered: