Merge remote-tracking branch 'origin/master' into swift-3-api-guidelines

This commit is contained in:
Max Moiseev
2015-12-07 16:43:20 -08:00
889 changed files with 18677 additions and 7911 deletions

View File

@@ -97,9 +97,8 @@ public struct EnumerateGenerator<
///
/// - Requires: No preceding call to `self.next()` has returned `nil`.
public mutating func next() -> Element? {
let b = base.next()
if b == nil { return .None }
return .Some((index: count++, element: b!))
guard let b = base.next() else { return .None }
return .Some((index: count++, element: b))
}
}