- Reactive Programming with Swift 4
- Navdeep Singh
- 62字
- 2021-06-24 18:58:02
Adding tuple destructuring
Consider code such as the following:
swift func foo(_: ((Int, Int) -> ()) {} foo { (x, y) in print(x + y) }
The migrator must add explicit tuple destructuring to continue building in Swift 4, such as shown here:
swift func foo(_: ((Int, Int) -> ()) {} foo { let (x, y) = $0; print(x + y) }
推薦閱讀
- HTML5+CSS3+JavaScript從入門到精通:上冊(cè)(微課精編版·第2版)
- Java編程指南:基礎(chǔ)知識(shí)、類庫(kù)應(yīng)用及案例設(shè)計(jì)
- Learning Firefox OS Application Development
- Kotlin Standard Library Cookbook
- Nginx Essentials
- Visual C++應(yīng)用開發(fā)
- Learning Python by Building Games
- Vue.js 2 Web Development Projects
- FPGA嵌入式項(xiàng)目開發(fā)實(shí)戰(zhàn)
- Python期貨量化交易實(shí)戰(zhàn)
- QlikView Unlocked
- WebStorm Essentials
- Visual Basic程序設(shè)計(jì)基礎(chǔ)
- C語(yǔ)言程序設(shè)計(jì)教程
- Oracle Database 12c DBA官方手冊(cè)(第8版)