Skip to main content

Crate rcal_macros

Crate rcal_macros 

Source

Attribute Macrosยง

guarded
Prepends let _monitor_guard = self.__monitor_mutex.lock().unwrap(); to a method body, acquiring the monitor mutex for the duration of the call.
init_test_logger
Attribute macro for test functions. Injects a logger variable at the top of the function body, built via rcal::logging::build_test_logger().
monitor
Injects a __monitor_mutex: ::std::sync::Mutex<()> field into a named-field struct.
rcal_main
Attribute macro for async fn main() (or another async entry point).
rcal_trace
Inserts slog::trace!(logger, "StructName::fn_name()") as the first statement of each function or method.