rjmccall added inline comments.

================
Comment at: clang/include/clang/Basic/AttrDocs.td:4409
+  calls to other ``swiftasynccall`` functions must be in tail position
+  (in all language modes). In particular:
+  - For C, this implies that ``return async_f();`` (``async_f`` is another
----------------
I don't think the "must be in tail position" here is true.  Allow me to suggest 
an alternative way of saying this:

> Within a `swiftasynccall` function, a call to a `swiftasynccall` function 
> that is the immediate operand of a `return` statement is guaranteed to be 
> performed as a tail call.  This syntax is allowed even in C as an extension 
> (a call to a `void`-returning function cannot be a `return` operand in 
> standard C).  If something in the calling function would semantically be 
> performed after a guaranteed tail call, such as the non-trivial destruction 
> of a local variable or temporary, then the program is ill-formed.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D95561/new/

https://reviews.llvm.org/D95561

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to