Share E-Book

AuthorTutorial Team, raywenderlich, Todorov, Marin

Master Swift’s new concurrency model! For years, writing powerful and safe concurrent apps with Swift could easily turn into a daunting task, full of race conditions and unexplained crashes hidden in a massive nesting of callback closures. In Swift 5.5, Apple introduced a new concurrency model featuring the async/await syntax, to let you write asynchronous code that reads like synchronous code. But like any new feature, here be dragons! So how will you achieve the much-desired mastery of Modern Swift Concurrency? Master Swift’s new concurrency model! For years, writing powerful and safe concurrent apps with Swift could easily turn into a daunting task, full of race conditions and unexplained crashes hidden in a massive nesting of callback closures. In Swift 5.5, Apple introduced a new concurrency model featuring the async/await syntax, to let you write asynchronous code that reads like synchronous code. But like any new feature, here be dragons! So how will you achieve the much-desired mastery of Modern Swift Concurrency? The new concurrency model provides everything you need to write safe and performant programs in Swift, including: • A new, native syntax for running asynchronous operations in a structured way. • A bundle of standard APIs to design asynchronous and concurrent code. • Low-level changes in the libdispatch framework, which make all the high-level changes integrate directly into the operating system. • A new level of compiler support for creating safe, concurrent code. Swift 5.5 introduces the new language syntax and APIs to support these features. In your apps, besides using a recent Swift version, you also need to target certain platform versions: • If you’re using Xcode 13.2 or newer, it will bundle the new concurrency runtime with your app so you can target iOS 13 and macOS 10.15 (for native apps). • In case you’re on Xcode 13 but earlier version than 13.2, you’ll be able to target only iOS 15 or macOS 12 (or newer). In the first chapter of the boo

AI Reading Assistant

Whole-book reading guide from stratified index samples; jump to passages in the text

Tags
AI categories
programming languageswiftconcurrency
ISBN: 1950325539
Publisher: Razeware LLC
Publish Year: 2021
Language: English
Pages: 273
File Format: PDF
File Size: 29.2 MB
Text Preview (First 20 pages)
Registered users can read the full content for free

Register as a Gaohf Library member to read the complete e-book online for free and enjoy a better reading experience.

Generating text preview…