zlib: refactor zlib module
This does several significant things:
- Refactors the structure of the zlib module, eliminating duplicated code, moving to ES6 classes for simplify inheritance, eliminating some closures and this->self uses. This was done in a way that should preserve API compat (no test changes were required at all for this piece).
- Makes errors more consistent and improves testing of errors.
Perf impact should be minimal if any.
Checklist
-
make -j4 test
(UNIX), orvcbuild test
(Windows) passes -
tests and/or benchmarks are included -
documentation is changed or added -
commit message follows commit guidelines
Affected core subsystem(s)
zlib