From 7d7b5f1a7071950965a9ddae55a494c142217ecd Mon Sep 17 00:00:00 2001 From: Jonathan Kew Date: Mon, 2 Oct 2023 19:19:03 +0000 Subject: [PATCH] Bug 1750945 - Remove legacy OldEscapeChars table. r=necko-reviewers,kershaw Differential Revision: https://phabricator.services.mozilla.com/D189701 --- xpcom/io/nsEscape.cpp | 29 ----------------------------- 1 file changed, 29 deletions(-) diff --git a/xpcom/io/nsEscape.cpp b/xpcom/io/nsEscape.cpp index bba0a1e435c8..226b44eb7c38 100644 --- a/xpcom/io/nsEscape.cpp +++ b/xpcom/io/nsEscape.cpp @@ -293,35 +293,6 @@ static bool dontNeedEscape(uint16_t aChar, uint32_t aFlags) { : false; } -// Temporary static assert to make sure that the rewrite to using -// `BuildEscapeChars` didn't change the final array in memory. -// It will be removed in Bug 1750945. - -static_assert([]() constexpr { - constexpr uint32_t OldEscapeChars[256] = - // clang-format off -// 0 1 2 3 4 5 6 7 8 9 A B C D E F -{ - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, // 0x - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, // 1x - 0,132095, 0,131584,132095, 0,132095,131696,132095,132095,132095,132095,132095,132095,132025,131856, // 2x !"#$%&'()*+,-./ - 132095,132095,132095,132095,132095,132095,132095,132095,132095,132095,132080,132080, 0,132080, 0,131840, // 3x 0123456789:;<=>? - 132080,132095,132095,132095,132095,132095,132095,132095,132095,132095,132095,132095,132095,132095,132095,132095, // 4x @ABCDEFGHIJKLMNO - 132095,132095,132095,132095,132095,132095,132095,132095,132095,132095,132095,132080, 896,132080, 896,132095, // 5x PQRSTUVWXYZ[\]^_ - 384,132095,132095,132095,132095,132095,132095,132095,132095,132095,132095,132095,132095,132095,132095,132095, // 6x `abcdefghijklmno - 132095,132095,132095,132095,132095,132095,132095,132095,132095,132095,132095, 896, 1012, 896,132095, 0, // 7x pqrstuvwxyz{|}~ DEL - 0 // 80 to FF are zero -}; - // clang-format on - - for (size_t i = 0; i < EscapeChars.size(); ++i) { - if (OldEscapeChars[i] != EscapeChars[i]) { - return false; - } - } - return true; -}()); - //---------------------------------------------------------------------------------------- /**