mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
[stdlib] Improve the flatMap deprecation message
<rdar://problem/36555646>
This commit is contained in:
@@ -448,7 +448,8 @@ extension Collection {
|
||||
return try _compactMap(transform)
|
||||
}
|
||||
|
||||
@available(*, deprecated, renamed: "compactMap(_:)")
|
||||
@available(*, deprecated, renamed: "compactMap(_:)",
|
||||
message: "Please use compactMap(_:) for the case where closure returns an optional value")
|
||||
@inline(__always)
|
||||
public func flatMap(
|
||||
_ transform: (Element) throws -> String?
|
||||
|
||||
Reference in New Issue
Block a user