I write one method in swift 1 like this :
public var array: [JSON]? {
get {
if self.type == .Array {
return map(self.object as! [AnyObject]){ JSON($0) }
} else {
return nil
}
}
}
when I install Xcode 7.2 (swift 2) this method give me error like this :
Cannot invoke 'map' with an argument list of type '([AnyObject],(_) -> _)'
now I want to know what is that problem?