import { decodeKey } from "https://deno.land/x/bencodex@0.2.2/src/decoder.ts";
Decodes a Bencodex key from the given buffer.
Note that this function does not check whether the given buffer is entirely consumed. You should check the returned DecodingState.read value by yourself to see if the buffer is entirely consumed.
Returns
An object that represents the end-state of decoding.