It turns out StringScanner works on bytes, not characters, which causes lots of subtle bugs when dealing with multibyte characters in Sass. This wrapper makes it work on bytes instead without too much loss of efficiency.
It's difficult to reliably engineer the STATIC_VALUE and STATIC_SELECTOR regexps to avoid any possible exponential explosion. Since they're so general, there are a lot of possible parses of any given valid subset of a property string or selector. This means that, if an invalid bit shows up far into the property/selector (where "invalid" could just mean "dynamic" or something otherwise unhandled by the static regexps), an exponential number of reparses of the preceding selector may need to be done. Two changes are introduced here to deal with this. First, static values will stop being parsed when a newline is found. This is probably correct anyway for formatting reasons; including newlines and indentation in the CSS output is unsightly. The second change limits the length of the static value to about 50 characters. This ensures that even if a long property/selector is on a single line, it won't go so long as to cause exponential explosion. Closes #92