Skip to content

Commit c07d491

Browse files
authored
Delete dead code from IdnMapping (dotnet#20857)
1 parent f8ba00e commit c07d491

File tree

1 file changed

+0
-9
lines changed
  • src/System.Private.CoreLib/shared/System/Globalization

1 file changed

+0
-9
lines changed

src/System.Private.CoreLib/shared/System/Globalization/IdnMapping.cs

-9
Original file line numberDiff line numberDiff line change
@@ -207,15 +207,6 @@ private string GetAsciiInvariant(string unicode, int index, int count)
207207
throw new ArgumentException(SR.Format(SR.Argument_InvalidCharSequence, unicode.Length - 1), nameof(unicode));
208208
}
209209

210-
// Have to correctly IDNA normalize the string and Unassigned flags
211-
bool bHasLastDot = (unicode.Length > 0) && IsDot(unicode[unicode.Length - 1]);
212-
213-
// Make sure we didn't normalize away something after a last dot
214-
if ((!bHasLastDot) && unicode.Length > 0 && IsDot(unicode[unicode.Length - 1]))
215-
{
216-
throw new ArgumentException(SR.Argument_IdnBadLabelSize, nameof(unicode));
217-
}
218-
219210
// May need to check Std3 rules again for non-ascii
220211
if (UseStd3AsciiRules)
221212
{

0 commit comments

Comments
 (0)