V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
V2EX 提问指南
konakona
V2EX  ›  问与答

so...swift2 取消了#是吗?

  •  
  •   konakona · 2015-10-09 21:45:40 +08:00 · 948 次点击
    这是一个创建于 3155 天前的主题,其中的信息可能已经有所发展或是发生改变。
    func createFamily(#MotherName:String,#FatherName:String)->String{
    return ("Mon:\(MotherName),Father:\(FatherName)")
    }

    Xcode 会提示并建议我写成 MotherName MotherName:String

    Version 7.0.1 (7A1001)
    第 1 条附言  ·  2015-10-20 18:56:49 +08:00

    没人么?

    而且我发现貌似_也被取消了:

    func testArgs(_name:String,_age:Int)->(){}
    testArgs("熊", 12)

    目前尚无回复
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   实用小工具   ·   5787 人在线   最高记录 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 145ms · UTC 02:12 · PVG 10:12 · LAX 19:12 · JFK 22:12
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.