def decode(worker: Worker, f: FileIn) -> Any: result = dec(f) worker.step() return result
def encode(worker: Worker, f: FileOut, x: Any) -> None: enc(f, x) worker.step()