Skip to content

Commit ec402de

Browse files
committed
Remove unused code
1 parent 55d622b commit ec402de

File tree

2 files changed

+1
-9
lines changed

2 files changed

+1
-9
lines changed

src/leetcode_env/list.rs

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -42,12 +42,6 @@ impl Debug for ListHead {
4242
}
4343
}
4444

45-
impl ListHead {
46-
fn new(head: Option<Box<ListNode>>) -> Self {
47-
ListHead { head }
48-
}
49-
}
50-
5145
impl From<ListHead> for Option<Box<ListNode>> {
5246
fn from(value: ListHead) -> Self {
5347
value.head

src/leetcode_env/tree.rs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,7 @@ impl TreeNode {
2323
right: None,
2424
}
2525
}
26-
fn wrapped_node(val: i32) -> Option<Rc<RefCell<Self>>> {
27-
Some(Rc::new(RefCell::new(Self::new(val))))
28-
}
26+
2927
fn wrapped_node_maybe(val: Option<i32>) -> Option<Rc<RefCell<Self>>> {
3028
val.map(|x| Rc::new(RefCell::new(Self::new(x))))
3129
}

0 commit comments

Comments
 (0)