fpgaminer / rust-lzma

A Rust crate that provides a simple interface for LZMA compression and decompression.
MIT License
79 stars 14 forks source link

finish should consume self #6

Closed fpgaminer closed 6 years ago

fpgaminer commented 8 years ago

Using LzmaWriter after calling finish is not a currently supported feature, so have finish consume self instead of &self.

Credits to krdln for the feedback.

NOTE: liblzma supports compressing/decompressing multiple xz streams. In the future the LzmaWriter API could be enhanced with a finish_and_continue method which finishes the current stream and then starts handling the next stream. Or something like that.