Xcode Version 9.4.1 (9F2000)
Apple Swift version 4.1.2 (swiftlang-902.0.54 clang-902.0.39.2)
(Also confirmed on 4.2-DEVELOPMENT-SNAPSHOT-2018-07-28-a at http://online.swiftplayground.run/)
This simple for-in clause causes an infinite loop:
It'll be resolved if you change String? to String.
See also the attached GIF.
However, I'm not really sure this is a bug or an expected behaviour.