Perhaps you're thinking about this choice of syntax from a different angle than was intended. `default` is not literally meant to be a "default value" or, in most cases, "the default case", rather a "default pattern"; a place for control to flow given no other option. Some other languages, especially those that emphasize patterns, syntaxize words like "otherwise" or simply use "_", but I've not seen languages that mix C-style switch-case keywords with C-style branching keywords before.
~Robert Widmann 2016/12/05 22:48、星野恵瑠 via swift-evolution <[email protected]> のメッセージ: > Many languages have a switch statement and most (maybe all?) of them use > "default" keyword for the condition which doesn't match any of those listed > in the switch statement. > > But sometimes that condition is just an exception, which literally IS NOT a > default condition. > > So how about using other keywords like "else" instead of "default"? > _______________________________________________ > swift-evolution mailing list > [email protected] > https://lists.swift.org/mailman/listinfo/swift-evolution _______________________________________________ swift-evolution mailing list [email protected] https://lists.swift.org/mailman/listinfo/swift-evolution
