blob: 3da8c632fe9908aebf0c671e9d7360c286458001 [file] [log] [blame]
//!
//! Implementation's internal macros
macro_rules! debug_fmt_fields {
($tyname:ident, $($($field:ident).+),*) => {
fn fmt(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
f.debug_struct(stringify!($tyname))
$(
.field(stringify!($($field).+), &self.$($field).+)
)*
.finish()
}
}
}
macro_rules! clone_fields {
($($field:ident),*) => {
fn clone(&self) -> Self {
Self {
$($field: self.$field.clone(),)*
}
}
}
}
macro_rules! ignore_ident{
($id:ident, $($t:tt)*) => {$($t)*};
}