~starkingdoms/starkingdoms

ref: 02df8a053b6bfd7d2ee9fbdbd60fe29137b63a7c starkingdoms/server/src/macros.rs -rw-r--r-- 323 bytes
02df8a05 — core Merge branch 'bevy_rewrite' of gitlab.com:starkingdoms.tk/starkingdoms.tk into bevy_rewrite 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
        }
    };
}