Unicode parsing fix: Support for >16-bit Unicode sequences by adding
parsing for surrogate pairs and encoding for 4-byte UTF8 sequences.