| ... | @@ -729,7 +729,11 @@ pub fn stringify(writer: anytype, value: anytype, options: std.json.Stringify.Op | ... | @@ -729,7 +729,11 @@ pub fn stringify(writer: anytype, value: anytype, options: std.json.Stringify.Op |
| 729 | try writer.writeAll("\""); | 729 | try writer.writeAll("\""); |
| 730 | for (value) |c| { | 730 | for (value) |c| { |
| 731 | try writer.writeAll(switch (c) { | 731 | try writer.writeAll(switch (c) { |
| 732 | 0x0c => "\\n", | 732 | 0x08 => "\\b", |
| | 733 | 0x09 => "\\t", |
| | 734 | 0x0a => "\\n", |
| | 735 | 0x0c => "\\f", |
| | 736 | 0x0d => "\\r", |
| 733 | 0x20...0x21 => &.{c}, | 737 | 0x20...0x21 => &.{c}, |
| 734 | 0x22 => "\\\"", | 738 | 0x22 => "\\\"", |
| 735 | 0x23...0x7e => &.{c}, | 739 | 0x23...0x7e => &.{c}, |
| ... | @@ -751,7 +755,11 @@ pub fn stringify(writer: anytype, value: anytype, options: std.json.Stringify.Op | ... | @@ -751,7 +755,11 @@ pub fn stringify(writer: anytype, value: anytype, options: std.json.Stringify.Op |
| 751 | try writer.writeAll("\""); | 755 | try writer.writeAll("\""); |
| 752 | for (&value) |c| { | 756 | for (&value) |c| { |
| 753 | try writer.writeAll(switch (c) { | 757 | try writer.writeAll(switch (c) { |
| 754 | 0x0c => "\\n", | 758 | 0x08 => "\\b", |
| | 759 | 0x09 => "\\t", |
| | 760 | 0x0a => "\\n", |
| | 761 | 0x0c => "\\f", |
| | 762 | 0x0d => "\\r", |
| 755 | 0x20...0x21 => &.{c}, | 763 | 0x20...0x21 => &.{c}, |
| 756 | 0x22 => "\\\"", | 764 | 0x22 => "\\\"", |
| 757 | 0x23...0x7e => &.{c}, | 765 | 0x23...0x7e => &.{c}, |