swift
e55387be - ExistentialSpecializer: don't copy guaranteed class existential arguments in the thunk

Commit
38 days ago
ExistentialSpecializer: don't copy guaranteed class existential arguments in the thunk The thunk copied a non-consumed class existential argument before opening it. This is not needed for guaranteed arguments, and it's wrong if the callee returns a guaranteed value which depends on the argument: an owned value cannot be the operand of such an apply, and the copy is destroyed right after the call. Instead, directly open the guaranteed argument and pass it to the callee. Fixes a compiler crash https://github.com/swiftlang/swift/issues/92982 rdar://189292385
Author
Committer
Parents
Loading