This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Foundation | |
infix operator ??? | |
extension Optional where Wrapped: Collection { | |
/// Performs a nil-coalescing operation, returning the wrapped value of an `Optional` instance | |
/// only if the wrapped value is not empty, otherwise returns a default value. | |
/// | |
/// - Parameters: |