Encode binary file to printable utf16be, and vice versa.
It is a MoonBit reimplementation of base16384.
fn decode(ArrayView[UInt16]) -> BytesView
fn decode_str(String) -> String raise
fn encode(BytesView) -> Array[UInt16]
fn encode_str(String) -> String///|
let input = "hello world"
let encoded = @base16384.encode_str(input)
let decoded = @base16384.decode_str(encoded)
inspect(encoded, content="栙擆羼湷槜瓆帀㴄")
inspect(decoded, content="hello world")