~starkingdoms/starkingdoms

ref: d056170f6eed7579afce1a8dc7b947a27e39b400 starkingdoms/server/src/macros.rs -rw-r--r-- 325 bytes
d056170f — core update CI DAG, make build, fmt, and clippy run in parallel 2 years ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#[macro_export]
macro_rules! err_or_cont {
    ($expr:expr) => {
        match $expr {
            Ok(n) => n,
            Err(_) => continue,
        }
    };
}
#[macro_export]
macro_rules! some_or_cont {
    ($expr:expr) => {
        match $expr {
            Some(n) => n,
            None => continue,
        }
    };
}