mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
When completing in the only expression of closure, use the return type of the closure as the type context for the code-completion. However, since code-completion may be on an incomplete input, we only use the return type to improve the quality of the result, not to mark it invalid, since (a) we may add another statement afterwards, or (b) if the context type is Void it doesn't need to match the value.
27 KiB
27 KiB