Function slog_stdlog::init
[−]
[src]
pub fn init() -> Result<(), SetLoggerError>
Register slog-stdlog as log backend.
This will pass all logging statements crated with log
crate to current slog-scope::logger().
#[macro_use] extern crate log; extern crate slog_stdlog; fn main() { slog_stdlog::init().unwrap(); // Note: this `info!(...)` macro comes from `log` crate info!("standard logging redirected to slog"); }