mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
Original fix for SR-9102 stripped throws bit from the function types nested inside optionals before attempting bindings, that doesn't work with e.g. default parameter values because conversions from throwing and non-throwing functions are only allowed in subtype relationship but function types nested inside optionals are going to be equated. So this patch takes an alternative approach and attempts to pattern match `nil` literal and `.none` use and classify argument as non-contributing to throws. Resolves: rdar://problem/47550715
28 KiB
28 KiB