Skip to content

Commit

Permalink
feat: impl the Default trait
Browse files Browse the repository at this point in the history
  • Loading branch information
Vlad2001MFS committed Jan 28, 2024
1 parent 0232305 commit 7bc507d
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1471,6 +1471,17 @@ impl<T> Grid<T> {
}
}

impl<T> Default for Grid<T> {
fn default() -> Self {
Self {
data: Vec::default(),
cols: 0,
rows: 0,
order: Order::default(),
}
}
}

impl<T: Clone> Clone for Grid<T> {
fn clone(&self) -> Self {
Grid {
Expand Down

0 comments on commit 7bc507d

Please sign in to comment.