Handle Unicode whitespace characters.

Unfortunately JavaScript allows any Unicode "space separator"
chars to be part of whitespace, so we need to pull off some
trickery to support all these chars in both Ruby 1.9+ (easy, as
it has Unicode support) and in 1.8 (fall back to byte-processing).