Serialization of lambdas with kwargs fails #56815
Labels
bug
Indicates an unexpected problem or unintended behavior
keyword arguments
f(x; keyword=arguments)
stdlib
Julia's standard library
Serialization/deserialization of anonymous functions with kwargs fails (no error if we remove the kwarg
; p = 1
below, or if we definef(; p = 1) = 0
instead of with a lambda)MWE
Interestingly, if we do
instead of
f = (; p = 2) -> 0
, we get no error, and the deserializedff()
evaluates correctlyThe key difference between the two definitions is apparent in lowering, which may give a clue as to a possible cause/fix
Thanks to @exaexa for his help in slack isolating the core issue (which affects Distributed in particular)!
Xref: JuliaLang/Distributed.jl#104
CC: @exaexa
The text was updated successfully, but these errors were encountered: