Control Flow
endAsync
$endAsync
$endAsync closes a block opened by $async[name]. It takes no argument.
Syntax
$endAsync
Behavior
- Every
$asyncneeds exactly one$endAsync. A missing one raisesMissing $endasync., a stray oneUnexpected $endasync.. - The statements after
$endAsyncstart immediately, while the body of the block runs at the same time. See$asyncfor the full semantics and limits (25 blocks per execution, text only available through$await).
Example
$async[work]
$var[result;done]
$var[result]
$endAsync
Started.
$await[work]
Try it
Paste an example into the playground to preview its message (functions that act on Discord are not run), or build the same thing with blocks.