From 3e0ecb247b40da88ca1dc76cf7f466cdcfb86387 Mon Sep 17 00:00:00 2001 From: Victor Zverovich Date: Sun, 4 Oct 2026 08:30:56 -0700 Subject: [PATCH] Remove redundant escape tests The U+1FAE0 and U+31350 cases added in #4962 duplicate the is_printable checks for the same code points. For a code point >= 0x80 needs_escape is exactly !is_printable(cp), and the existing U+1F984 case already covers a printable 4-byte sequence passing through unmodified. --- test/ranges-test.cc | 3 --- 1 file changed, 3 deletions(-) diff --git a/test/ranges-test.cc b/test/ranges-test.cc index d431e98a..8a9a0832 100644 --- a/test/ranges-test.cc +++ b/test/ranges-test.cc @@ -623,9 +623,6 @@ TEST(ranges_test, escape) { // Correct utf-8. EXPECT_EQ(fmt::format("{}", vec{"🦄"}), "[\"🦄\"]"); - EXPECT_EQ(fmt::format("{}", vec{"🫠"}), "[\"🫠\"]"); - EXPECT_EQ(fmt::format("{}", vec{"\xf0\xb1\x8d\x90"}), - "[\"\xf0\xb1\x8d\x90\"]"); } EXPECT_EQ(fmt::format("{}", std::vector>{{'x'}}),