Why conditional let
isn't considered as a Boolean value? To me it looks quite natural to write something like:
while let myInt = iterator.next() as? Int {
if myInt > 666 { ... }
}
but nope, the compiler doesn't accept it.
To overcome that I can see nothing better than
while true {
guard let myInt = iterator.next() as? Int else {break}
if myInt > 666 {...}
}
which looks really bizzaire to me.