After briefly thinking about negative character classes, my initial instinct is that they will require a pretty fundamental change to the NFA data structure being used. Characters and character classes are currently handled by enumerating all of the characters in the class and creating a transition in the NFA for each one.

The fundamental problem is that the implementation isn’t scalable. A regex like ‘[a-\u0xffff]{10}’ will blow up memory. To create a negative character class would require enumerating every unicode character not in the set. Also infeasible.

For the time being I’m going to ignore the problem while working on the code to convert the NFA to a DFA.