1
1
mirror of https://github.com/tweag/nickel.git synced 2024-11-10 10:46:49 +03:00

style: Derive Default instance

This commit is contained in:
Mathieu Boespflug 2021-12-28 16:58:51 +02:00
parent 5e64bcc82d
commit e6a6b47b76

View File

@ -155,17 +155,11 @@ impl From<MetaValue> for Term {
}
}
#[derive(Debug, Eq, PartialEq, Copy, Clone)]
#[derive(Debug, Default, Eq, PartialEq, Copy, Clone)]
pub struct RecordAttrs {
pub open: bool,
}
impl Default for RecordAttrs {
fn default() -> Self {
RecordAttrs { open: false }
}
}
impl RecordAttrs {
pub fn merge(attrs1: RecordAttrs, attrs2: RecordAttrs) -> RecordAttrs {
RecordAttrs {