The following code does not compile giving the following error diagnostic:
Function is not differentiable
Differentiated functions in '@inlinable' functions must be marked '@differentiable' or have a public '@derivative'; this is not possible with a closure, make a top-level function instead
This is incorrect however as the function itself is not a closure and is differentiable.
Description
The following code does not compile giving the following error diagnostic:
This is incorrect however as the function itself is not a closure and is differentiable.
Reproduction
Expected behavior
Compile without error
Environment
Apple Swift version 6.0-dev (LLVM 097782ee554d9fe, Swift 60bf038ce965551) Target: arm64-apple-macosx14.0
Additional information
No response