prev isn't used atm
This commit is contained in:
@@ -7,7 +7,6 @@ use crate::{
|
|||||||
};
|
};
|
||||||
|
|
||||||
struct LayerNode {
|
struct LayerNode {
|
||||||
prev: Option<usize>,
|
|
||||||
next: Next,
|
next: Next,
|
||||||
child: Option<usize>,
|
child: Option<usize>,
|
||||||
data: Layer,
|
data: Layer,
|
||||||
@@ -57,7 +56,6 @@ impl Layers {
|
|||||||
}
|
}
|
||||||
let i_next = self.push(LayerNode::new(Layer::default(), self.vec[i].next));
|
let i_next = self.push(LayerNode::new(Layer::default(), self.vec[i].next));
|
||||||
self.vec[i].next = Next::Same(i_next);
|
self.vec[i].next = Next::Same(i_next);
|
||||||
self.vec[i_next].prev = Some(i);
|
|
||||||
i_next
|
i_next
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -67,7 +65,6 @@ impl Layers {
|
|||||||
}
|
}
|
||||||
let i_next = self.push(LayerNode::new(Layer::default(), Next::Parent(i)));
|
let i_next = self.push(LayerNode::new(Layer::default(), Next::Parent(i)));
|
||||||
self.vec[i].child = Some(i_next);
|
self.vec[i].child = Some(i_next);
|
||||||
self.vec[i_next].prev = Some(i);
|
|
||||||
i_next
|
i_next
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -116,7 +113,6 @@ impl IndexMut<usize> for Layers {
|
|||||||
impl LayerNode {
|
impl LayerNode {
|
||||||
pub fn new(data: Layer, next: Next) -> Self {
|
pub fn new(data: Layer, next: Next) -> Self {
|
||||||
Self {
|
Self {
|
||||||
prev: None,
|
|
||||||
next,
|
next,
|
||||||
child: None,
|
child: None,
|
||||||
data,
|
data,
|
||||||
|
|||||||
Reference in New Issue
Block a user