I want to use alias defined in the Class1 class . I want to use it into Class2
import UIKit
class Class1: NSObject {
typealias tp = () -> Void
}
import UIKit
class Class2: NSObject {
func pingTest(){
var test:tp?
}
}
Class2 throws compile time error at var test:tp?
Also, the autocompletion does not work. Screen the shot attached with this email. I tried the following thing but that didn't work for me (XCode 6 isn't autocompleting in swift).