fix: Don't create empty path nodes

This commit is contained in:
Lukas Wirth 2024-12-04 06:49:27 +01:00
parent b6fc9c14ac
commit caba872f88
6 changed files with 26 additions and 24 deletions

View file

@ -327,10 +327,10 @@ impl Marker {
self.bomb.defuse();
let idx = self.pos as usize;
if idx == p.events.len() - 1 {
match p.events.pop() {
Some(Event::Start { kind: TOMBSTONE, forward_parent: None }) => (),
_ => unreachable!(),
}
assert!(matches!(
p.events.pop(),
Some(Event::Start { kind: TOMBSTONE, forward_parent: None })
));
}
}
}