Merge branch 'develop' of https://github.com/coverxit/the-swift-programming-language-in-chinese into develop
Conflicts: source/chapter2/05_Control_Flow.md
This commit is contained in:
@ -519,4 +519,4 @@ case let (x, y):
|
||||
|
||||
这三个*case*都声明了常量`x`和`y`的占位符,用于临时获取元组`yetAnotherPoint`的两个值。这些常量被用作`where`语句的一部分,从而创建一个动态的过滤器(filter)。当且仅当`where`语句的条件为`真`时,匹配到的*case*块才会被执行。
|
||||
|
||||
就像是值绑定中的例子,由于最后一个*case*块匹配了余下所有可能的值,`switch`语句就已经完备了,因此不需要再书写默认块。
|
||||
就像是值绑定中的例子,由于最后一个*case*块匹配了余下所有可能的值,`switch`语句就已经完备了,因此不需要再书写默认块。
|
||||
@ -375,4 +375,4 @@ return `expression`
|
||||
|
||||
> GRAMMAR OF A RETURN STATEMENT
|
||||
|
||||
> *return-statement* → **return** [*expression*](https://developer.apple.com/library/prerelease/ios/documentation/Swift/Conceptual/Swift_Programming_Language/Expressions.html#//apple_ref/swift/grammar/expression) *opt*
|
||||
> *return-statement* → **return** [*expression*](https://developer.apple.com/library/prerelease/ios/documentation/Swift/Conceptual/Swift_Programming_Language/Expressions.html#//apple_ref/swift/grammar/expression) *opt*
|
||||
|
||||
Reference in New Issue
Block a user