Macro pgde::pg_type_expr_implementation

source ·
macro_rules! pg_type_expr_implementation {
    ( $( $x:ty, $y:expr ),* ) => { ... };
}
Expand description

A macro for implementing from_row on primitive types that defaults to a provided expression. Used internally to implement from_row on SystemTime and IpAddr.

§Example

pg_type_expr_implementation![
    SystemTime,
    SystemTime::now()
]