Macro aorist_extendr_api::var [−][src]
macro_rules! var { ($($tokens : tt) *) => { ... }; }
Expand description
Get a local variable from the calling function or a global variable if no such variable exists.
Variables with embedded “.” may not work.
use extendr_api::prelude::*; test! { current_env().set_local(sym!(myvar), 1.0); assert_eq!(var!(myvar), Ok(r!(1.0))); }