fix write_canonical on strings (#1233)

This commit is contained in:
Mark Thom
2022-02-05 20:40:28 -07:00
parent 7b8001d060
commit 2f0718e885

View File

@@ -1148,10 +1148,6 @@ impl<'a, Outputter: HCValueOutputter> HCPrinter<'a, Outputter> {
if end_cell == empty_list_as_cell!() { if end_cell == empty_list_as_cell!() {
append_str!(self, "[]"); append_str!(self, "[]");
} else { } else {
if self.outputter.ends_with(",") {
self.outputter.truncate(self.outputter.len() - ','.len_utf8());
}
self.state_stack.push(TokenOrRedirect::FunctorRedirect(max_depth)); self.state_stack.push(TokenOrRedirect::FunctorRedirect(max_depth));
self.iter.push_stack(end_h); self.iter.push_stack(end_h);
} }