Reputation: 430
This question is basically to study, there is no "why?" or "instead of ..."
In Swift 3 it is very common to use the .default, exemplifying:
UIApplication.shared.statusBarStyle = .default // from UIStatusBarStyle.default
And I was thinking, how? In my tests I did not succeed, I try something like:
class Test { enum Options { case light, default // bad world } }
Thank you :)
Upvotes: 1
Views: 185
Reputation: 5186
Do like this:
class Test {
enum Options:Int {
case `default`
case lightContent
}
}
Upvotes: 6