run(expr) with an expression directly writen, will parse that
expression as a coroutine, but then run it without pausing.
A generator expression, same as you would write in gen.
A value whose mode will determine the output vector mode (as in vapply.)
See async; defaults to FALSE.
Will open a browser at the first and subsequent R evaluations allowing single-stepping through user code.
Will set a breakpoint at the implementation
level, allowing single-stepping through
async package code.
a tracing function.
expr contains any
yield calls, a vector of the
same mode as
type; otherwise the return value of
If the expression contains any calls to
collect all the values passed to yield() and return a list. If the
expression contains a
yield() but it is never called,
returns an empty list. If the expression does not contain a
run returns the expression's final return value.
run(expr) is similar to
evaluates its expression directly in the calling environment, while
gen creates a new enclosed environment to run in.
run is useful if you want to take advantage of coroutine language
extensions, such as using
for loops over iterators, or using
switch statements, in otherwise synchronous code. If
you want to collect a variable-length sequence of values but don't
need those features, using collect directly will have better