// Playground 延時(shí)運(yùn)行
// 及時(shí)編輯的 REPL 環(huán)境
// cmd + option + 回車顶滩, 打開輔助編輯器命满,可以看到時(shí)間軸
import PlaygroundSupport
PlaygroundPage.current.needsIndefiniteExecution = true
class Foo{
@objc func show(){
print("Hi")
}
}
let obj = Foo()
Timer.scheduledTimer(timeInterval: 1, target: obj, selector: #selector(Foo.show), userInfo: nil, repeats: true)