[SR-6554] Type inference error when applying optional function to optional value #49104
Labels
bug
A deviation from expected or documented behavior. Also: expected but undesirable behavior.
compiler
The Swift compiler in itself
regression
swift 4.0
Environment
Swift 4.0, Swift 4.0.1
Additional Detail from JIRA
md5: d5270fb56c4a13ba96b13a49017fdb53
Issue Description:
Possibly related to bug: https://bugs.swift.org/browse/SR-6509
This works fine under Swift3-3.2.
Actual results:
'apply' produces 'Result?', not the expected contextual result type 'Result?'
Expected results:
The code compiles, compiler infers the type of result for type of Wrapped
The text was updated successfully, but these errors were encountered: