1.关于inout.net
在Swift2.2中get
func change( inout a:Int, inout _ b: Int){io
let t = aclass
a = b方法
b = tim
}协议
在Swift3.0中co
func change( a:inout Int, _ b: inout Int){let
let t = aprotocol
a = b
b = t
}
2.协议中的可选方法
在Swift2.2中
@objc protocol Animal {
//定义可选方法
optional func wing()
}
在Swift3.0中
@objc protocol Animal {
//定义可选方法
@objc optional func wing()
}