authorgravatar for hello@nektro.netMeghan Denny <hello@nektro.net> 2026-01-19 01:53:49 -08:00
committergravatar for hello@nektro.netMeghan Denny <hello@nektro.net> 2026-01-19 01:53:49 -08:00
logba472f055e4e641958202b0229ef52a8c5193d8b
treee8a47ee27642bff8ac271ca7540bb8e8a8461d98
parentf8e9e53b4f547ebc4f926a6c4cd67fe8055a1db0

remove this commented out code


2 files changed, 1 insertions(+), 10 deletions(-)

idna.zig-3
...@@ -19,8 +19,6 @@ pub fn ToASCII(...@@ -19,8 +19,6 @@ pub fn ToASCII(
19 VerifyDnsLength: bool,19 VerifyDnsLength: bool,
20 IgnoreInvalidPunycode: bool,20 IgnoreInvalidPunycode: bool,
21) ![]u8 {21) ![]u8 {
22 // if (extras.matchesAll(u8, domain_name, std.ascii.isAscii)) return allocator.dupe(u8, domain_name);
23
24 var map = extras.ManyArrayList(u8).init(allocator);22 var map = extras.ManyArrayList(u8).init(allocator);
25 defer map.deinit();23 defer map.deinit();
2624
...@@ -56,7 +54,6 @@ pub fn ToUnicode(...@@ -56,7 +54,6 @@ pub fn ToUnicode(
56 Transitional_Processing: bool, //deprecated54 Transitional_Processing: bool, //deprecated
57 IgnoreInvalidPunycode: bool,55 IgnoreInvalidPunycode: bool,
58) ![]u8 {56) ![]u8 {
59 // if (extras.matchesAll(u8, domain_name, std.ascii.isAscii)) return allocator.dupe(u8, domain_name);
60 var map = extras.ManyArrayList(u8).init(allocator);57 var map = extras.ManyArrayList(u8).init(allocator);
61 defer map.deinit();58 defer map.deinit();
62 try Processing(&map, domain_name, UseSTD3ASCIIRules, CheckHyphens, CheckBidi, CheckJoiners, Transitional_Processing, IgnoreInvalidPunycode);59 try Processing(&map, domain_name, UseSTD3ASCIIRules, CheckHyphens, CheckBidi, CheckJoiners, Transitional_Processing, IgnoreInvalidPunycode);
normalization.zig+1-7
...@@ -178,13 +178,7 @@ fn CanonicalComposition(map: *extras.ManyArrayList(u8)) !void {...@@ -178,13 +178,7 @@ fn CanonicalComposition(map: *extras.ManyArrayList(u8)) !void {
178178
179 const slt = map.items(i + 2);179 const slt = map.items(i + 2);
180 const cpt = std.unicode.utf8Decode(slt) catch unreachable;180 const cpt = std.unicode.utf8Decode(slt) catch unreachable;
181 if ((hangul_syllable_type(cpt) orelse {181 if ((hangul_syllable_type(cpt) orelse continue) != .T) continue;
182 // try composeHangulSyllable2(map, i, cpl, cpv);
183 continue;
184 }) != .T) {
185 // try composeHangulSyllable2(map, i, cpl, cpv);
186 continue;
187 }
188 std.debug.assert(cpt >= 0x11A8 and cpt <= 0x11C2);182 std.debug.assert(cpt >= 0x11A8 and cpt <= 0x11C2);
189 // seq is <L,V,T>183 // seq is <L,V,T>
190 try composeHangulSyllable3(map, i, cpl, cpv, cpt);184 try composeHangulSyllable3(map, i, cpl, cpv, cpt);