Fix rot13 UTF-8 bug

This commit is contained in:
rany2 2023-06-18 14:36:56 +03:00 committed by GitHub
parent 3534bf6ff9
commit 08ae243ac6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -60,7 +60,7 @@ public final class Rot13 : Mod
ch = (ch - 'a' + 13) % 26 + 'a';
if (ch >= 'A' && ch <= 'Z')
ch = (ch - 'A' + 13) % 26 + 'A';
return ch.to!char;
return ch.to!wchar;
}));
}
}