diff --git a/CHANGELOG.md b/CHANGELOG.md index 31b33c809..a4995a0cb 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,6 +3,8 @@ * Produce better output for numbers with complex units in `meta.inspect()` and debugging messages. +* Escape U+007F DELETE when serializing strings. + * When generating CSS error messages to display in-browser, escape all code points that aren't in the US-ASCII region. Previously only code points U+0100 LATIN CAPITAL LETTER A WITH MACRON were escaped. diff --git a/lib/src/visitor/serialize.dart b/lib/src/visitor/serialize.dart index 676a4876b..9ab203073 100644 --- a/lib/src/visitor/serialize.dart +++ b/lib/src/visitor/serialize.dart @@ -1090,7 +1090,8 @@ final class _SerializeVisitor $fs || $gs || $rs || - $us: + $us || + $del: _writeEscape(buffer, char, string, i); case $backslash: diff --git a/pubspec.yaml b/pubspec.yaml index 6f666281e..c42d2133e 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -42,7 +42,7 @@ dev_dependencies: archive: ^3.1.2 crypto: ^3.0.0 dart_style: ^2.0.0 - dartdoc: ">=6.0.0 <8.0.0" + dartdoc: ">=6.0.0 <9.0.0" grinder: ^0.9.0 node_preamble: ^2.0.2 lints: ">=2.0.0 <4.0.0"