-
Notifications
You must be signed in to change notification settings - Fork 118
"/[]/" breaks syntax highlighting #244
Comments
I mean, this is technically correct. You can't have an empty character class. http://php.net/manual/en/regexp.reference.character-classes.php (emphasis mine)
|
If the string is necessarily a regex, I guess that's the right call. But it could just be a string that happens to have those 4 characters, right? This would be valid PHP, and also break the coloring of the whole file: <?php
$x = "/[]/";
echo $x;
// ... Could the pattern terminate at line end? |
Hmm...I was under the impression that |
@50Wliu to add to that, regex delimiters are not just limited to |
Can repro in VS Code and Atom.
string.regexp.character-class.php
never ends.The text was updated successfully, but these errors were encountered: