Avatar
@swift-4.2.4 func check1(_ x: Int??) { var x = x x? = 2 print(x as Any) } func check2(_ x: Int??) { var x = x x?? = 2 print(x as Any) } var x1: Int?? = .none var x2: Int?? = .some(.none) var x3: Int?? = .some(.some(1)) check1(x1) check2(x1) print("--") check1(x2) check2(x2) print("--") check1(x3) check2(x3) (edited)