# Async, await and @autoclosure

**URL:** <https://forums.swift.org/t/async-await-and-autoclosure/47614>\
**Category:** Discussion\
**Created:** [April 22, 2021, 3:27am UTC](https://forums.swift.org/t/async-await-and-autoclosure/47614 "2021-04-22T03:27:25Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![xwu](https://avatars.discourse-cdn.com/v4/letter/x/b487fb/32.png) [@xwu](https://forums.swift.org/u/xwu)\
**Post date:** [April 22, 2021, 3:55am UTC](https://forums.swift.org/t/async-await-and-autoclosure/47614/2 "2021-04-22T03:55:53Z")

</div>

> [@George](#):
>
> ```swift
> /// Error: call is 'async' in an autoclosure argument that is not marked with 'await'
> let _ = await foo() | bar()
> 
> ```

Seems like a bug.

> [@George](#):
>
> There is some discussion of `async` , `await` , and `@autoclosure` [here](https://github.com/apple/swift-evolution/blob/main/proposals/0296-async-await.md#autoclosures), but it doesn't mention operators and it isn't 100% clear on the how the compiler would interpret `await computeArgumentLater(await getIntSlowly())` (my reading of this is that there would be a suspension point both prior to _and_ in the body of `computeArgumentLater` ).
> 
> Overall, I think the right move is to only apply autoclosure semantics when an argument is _not_ labeled `await` .

The point of the discussion in the proposal is that only one `await` is ever required per statement, just like only one `try` is ever required per statement, and how autoclosures must work in order to observe that principle.

---

_[View the full topic](https://forums.swift.org/t/async-await-and-autoclosure/47614)._
