排序
What’s the difference between await and async let? await 和 async let 有什么区别?
Swift lets us perform async operations using both await and async let, but although they both run some async code they don’t quite run the same: await wai...
How to create and call an async function如何创建和调用异步函数
Using async functions in Swift is done in two steps: declaring the function itself as being async, then calling that function using await.在 Swift 中使用异步函数分两步完...
How to create and use async properties 如何创建和使用异步属性
Just as Swift’s functions can be asynchronous, computed properties can also be asynchronous: attempting to access them must also use await or similar, and may also need&...
How to fix the error “async call in a function that does not support concurrency” 如何修复错误 “async call in a function that does not support concurrency”
This error occurs when you’ve tried to call an async function from a synchronous function, which is not allowed in Swift – asynchronous functions must be able to suspend the...
Why can’t we call async functions using async var? 为什么我们不能使用 async var 调用 async 函数?
Swift’s async let syntax provides short, helpful syntax for running lots of work concurrently, allowing us to wait for them all later on. However, it only works as ...