Improve javascript regex character class handling

A small tweak to improve handling of regular expressions. This does two things:

First, it makes the highlighter understand character classes, which means that it knows that / doesn't end the regex in there.
Second, regexes that span lines are now flagged as errors.