implement ListElisionPolicy to restore previous printer behavior

This commit is contained in:
Mark
2023-09-30 16:00:15 -06:00
parent 25afc11168
commit 62c23166fa
9 changed files with 134 additions and 98 deletions

View File

@@ -1135,7 +1135,8 @@ impl MachineState {
return false;
}
let mut iter = stackful_preorder_iter(&mut self.heap, &mut self.stack, value);
let mut iter = stackful_preorder_iter::<NonListElider>
(&mut self.heap, &mut self.stack, value);
while let Some(value) = iter.next() {
if value.get_forwarding_bit() {
@@ -1633,7 +1634,7 @@ impl MachineState {
}
let mut visited = IndexSet::with_hasher(FxBuildHasher::default());
let mut iter = stackful_preorder_iter(&mut self.heap, &mut self.stack, value);
let mut iter = stackful_preorder_iter::<NonListElider>(&mut self.heap, &mut self.stack, value);
let mut stack_len = 0;
while let Some(value) = iter.next() {