Open luchr opened 1 month ago
This appears to be a bug in tmerge that goes back at least as far as 1.6. Good to see that it's fixed in 1.11.
specifically, the bug is that
T = Tuple{}
T_old = Union{}
while T != T_old
T_old, T = T, Core.Compiler.tmerge(T, Tuple{T, Tuple{}})
end
is an infinite loop prior to 1.11
This was likely fixed by some combination of https://github.com/JuliaLang/julia/pull/55757, https://github.com/JuliaLang/julia/pull/50927, and https://github.com/JuliaLang/julia/pull/53876. @Keno, @vtjnash any opinions on the backport-ability of these?
Take the following test file
nestedtuples.jl
:The function
please_return
does not terminate (julia hangs forever) for version 1.10.5. It does terminate and returns the expected result in version 1.11.0 though.Output:
For comparison the output of 1.11:
Is this a known bug/feature?