Closed mikepinkerton closed 2 years ago
Looks like this has been fixed in ToT (Apple Swift version 5.7-dev (LLVM 0111970099b6de6, Swift b6ec1874c96449c)).
It results in a compile error that it cannot convert the return expression of type Int32
to return type Int
.
If this is resolved, I'm going to close it. Please let me know if you see this issue again in the future. Thank you for the continued, high-quality bug reports. Having small reproducers like this really helps.
In Xcode 13.3 (Swift 5.6) with C++ interop, the following will crash the compiler:
(in .h)
(in .swift)
Note that if you change the result of
addObjects
to beInt32
it compiles and runs correctly. Having it asInt
is the problem.Here's the output: