Fix UB in conversion functions (#5)
Fix UB in conversion functions (#5)

UB due to violation of strict aliasing rule,
fixing by copying to an intermediate buffer.
yhirose/cpp-unicodelib,yhirose/cpp-unicodelib