--- source: tests/output.rs expression: "get_stdout(&[item])" --- anyhow Typedef anyhow::Result rusty-man SYNOPSIS type Result = Result; DESCRIPTION `Result` This is a reasonable return type to use throughout your application but also for `fn main`; if you do, failures will be printed along with any [context][Context] and a backtrace if one was captured. `anyhow::Result` may be used with one *or* two type parameters. use anyhow::Result; fn demo1() -> Result {...} // ^ equivalent to std::result::Result fn demo2() -> Result {...} // ^ equivalent to std::result::Result # Example use anyhow::Result; fn main() -> Result<()> { let config = std::fs::read_to_string("cluster.json")?; let map: ClusterMap = serde_json::from_str(&config)?; println!("cluster info: {:#?}", map); Ok(()) }