pub fn decode(input_str: &str, remainder_length: Option<u32>) -> Result<Vec<u8>>Expand description
Decode a string encoded in the Asyntactic script. Return an array of pseudo-booleans (0 or 1).
remainderLength is not in the original version of this code. It should be provided to get round-trip output. It is the input length in bits, mod the number of bits per character (the second argument to the encode function). Other fixes to decoding are also made if remainderLength is provided. If it is not provided, the output should be the same as with original API (if not, that’s a bug) - WITH THE EXCEPTION that in some cases the original version sometimes returned NaN for some bits. See the tests for an example. I haven’t looked into why that is.
Pass None as the remainder_length to use per the original API.