Daily Shaarli
September 5, 2024
Reasonable Colors is an open-source color system for building accessible, nice-looking color palettes.
Since Rust 1.65:
let Some(user) = get_user() else {
return Err("No user".into());
};
The option can also be handled with .ok_or()
if it's recoverable.
The last solution is to use the match
statement.