parse_export_specs {box} | R Documentation |
Find exported names in parsed module source
Description
Find exported names in parsed module source
Usage
parse_export_specs(info, exprs, mod_ns)
use_call
static_assign_calls
assign_calls
is_static_assign_call(call)
is_assign_call(call)
block_is_assign(block)
block_is_use_call(block)
block_is_exported(block)
block_name(block)
Arguments
info |
The module info. |
exprs |
The list of expressions of the parsed module. |
mod_ns |
The module namespace after evaluating the expressions. |
call |
A call to test. |
block |
A roxygen2 block to inspect. |
Format
An object of class call
of length 3.
An object of class list
of length 4.
An object of class list
of length 6.
Value
parse_export_specs
returns a potentially empty character
vector of exported names.
Note
There are two situations in which the @export
tag can be applied:
When applied to assignments, the assigned name is exported.
When applied to a
box::use
call, the imported names are exported. This can be the module name itself, any attached names, or both. All names introduced by thebox::use
call are exported. Seeuse
for the rules governing what names are introduced into the scope, and thus exported.
In any other situation, applying the @export
tag is an error.