Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func UTF16Decode ¶
UTF16Decode returns the Unicode code point sequence represented by the UTF-16 encoding rune values supplied.
func UTF16EncodeStd ¶
UTF16EncodeStd encodes the runes into a UTF16 array and ignores zero points.
This is ONLY safe to use if you know what you're doing.
func UTF16FromString ¶
UTF16FromString returns the UTF-16 encoding of the UTF-8 string with a terminating NUL added.
If the string contains a NUL byte at any location, it returns syscall.EINVAL.
func UTF16PtrFromString ¶
UTF16PtrFromString returns pointer to the UTF-16 encoding of the UTF-8 string, with a terminating NUL added.
If the string contains a NUL byte at any location, it returns syscall.EINVAL.
func UTF16PtrToString ¶
UTF16PtrToString takes a pointer to a UTF-16 sequence and returns the corresponding UTF-8 encoded string.
If the pointer is nil, it returns the empty string. It assumes that the UTF-16 sequence is terminated at a zero word; if the zero word is not present, the program may crash.
func UTF16ToString ¶
UTF16ToString returns the UTF-8 encoding of the UTF-16 sequence s, with a terminating NUL and any bytes after the NUL removed.