Avoid infinite recursion causing StackOverflowException by directly
modifying the character class map