Avatar
omochimetaru 4/26/2018 5:47 AM
extension Collection where SubSequence == Self { /// Removes and returns the first element of the collection. /// /// - Returns: The first element of the collection if the collection is /// not empty; otherwise, `nil`. /// /// - Complexity: O(1) @_inlineable public mutating func popFirst() -> Element? { // TODO: swift-3-indexing-model - review the following guard !isEmpty else { return nil } let element = first! self = self[index(after: startIndex)..<endIndex] return element } }
5:47 AM
'[String]' requires the types '[String]' and 'ArraySlice<String>' be equivalent
5:47 AM
このメッセージはこのwhereから来てるものか。