rich_range 0.1.0

Range calculation helper.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
//! Utility macros.

/// Convert the expression to a reference.
///
/// if it's already a reference, pass the reference symbol as the
/// first argument. Otherwise pass the empty as the first argument.
macro_rules! to_ref {
    (, $expr:expr) => {
        &$expr
    };
    (&, $expr:expr) => {
        $expr
    };
}

pub(crate) use to_ref;