Skip to main content

AsFunction

Trait AsFunction 

Source
pub trait AsFunction {
    // Required method
    fn as_function(&self) -> Result<SEXP, AsCoerceError>;
}
Expand description

Trait for types that can be coerced to function via as.function().

The result should be an R function (closure).

Required Methods§

Source

fn as_function(&self) -> Result<SEXP, AsCoerceError>

Convert to an R function.

Implementors§