mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
The issue is that the shorthand if let syntax injects an implicit expression: https://github.com/apple/swift/pull/40694/ in ParseStmt and that the 'diagnoseUnhandledAsyncSite' explicitly avoids reporting errors in implicit expressions. This change is that we don't mark the implicit declref code emitted by the `if let prop` as implicit anymore, and this way the reporting works out as expected. Added some tests covering this as well as properly erroring out for the nonexistent syntax of shortand + awaiting which doesn't exist, and we properly error on it. Resolves rdar://126169564