spray/spray — pull request #855 by chadselph (2014-05-01 08:46:04+00:00)
Title: fix for non-BMP characters when encoding URIs

Currently, the URL-encoder encodes the surrogate pairs of a non-BMP character instead of the character itself. For example, U+1F4A9 should be encoded as "%F0%9F%92%A9" but instead, each of its pairs ("\ud83d" and "\udca9") get encoded, producing a total of 6 bytes instead of 4.

The new approach uses the `codePointAt` API instead of `charAt` which returns an Integer of the unicode codepoint, instead of Char.