[swift-evolution] [swift-evolution-announce] [Review] SE-0099: Restructuring Condition Clauses

Christopher Kornher ckornher at mac.com
Tue May 31 14:45:57 CDT 2016


> 
> Not allowed:
>> let a = a
> let b = b where b > 10 && a > 5
> 
> Why would this not be allowed by your rule? You're making use of `b` in your where clause. As I demonstrated above, essentially any assertion can be rewritten to work around your rule. In general:

It is not allowed because  ‘a’ is defined in the line above. It must be defined in the ‘if let’ associated with the where in which it is mentioned.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-evolution/attachments/20160531/8986cccb/attachment.html>


More information about the swift-evolution mailing list