Bug 14799 – Documentation for std.zlib.compress is incorrect

Status
RESOLVED
Resolution
FIXED
Severity
minor
Priority
P1
Component
phobos
Product
D
Version
D2
Platform
All
OS
All
Creation time
2015-07-14T20:15:00Z
Last change time
2015-10-04T18:20:38Z
Keywords
pull
Assigned to
nobody
Creator
briancschott

Comments

Comment #0 by briancschott — 2015-07-14T20:15:39Z
The documentation for std.zlib.compress states that the valid values for the "level" parameter are 1-9, with 6 being the default. The actual valid values are 0-9, and there is no default argument for the level parameter.
Comment #1 by briancschott — 2015-07-14T20:25:30Z
Correction: The valid values are -1 through 9 (inclusive). -1 is Z_DEFAULT_COMPRESSION, which is -1. This -1 gets translated to 6 inside the C library.
Comment #2 by dlang-bugzilla — 2015-09-01T05:40:40Z
Comment #3 by github-bugzilla — 2015-09-01T06:42:21Z
Commits pushed to master at https://github.com/D-Programming-Language/phobos https://github.com/D-Programming-Language/phobos/commit/07422ed9a6a1f0d0c48acdb75fd1f9a8e0cd36a5 fix Issue 14799 - Documentation for std.zlib.compress is incorrect https://github.com/D-Programming-Language/phobos/commit/5f165ae4eeac55b909ab2a10feda1434c7c40b74 Merge pull request #3618 from CyberShadow/pull-20150901-053959 fix Issue 14799 - Documentation for std.zlib.compress is incorrect
Comment #4 by github-bugzilla — 2015-10-04T18:20:38Z
Commits pushed to stable at https://github.com/D-Programming-Language/phobos https://github.com/D-Programming-Language/phobos/commit/07422ed9a6a1f0d0c48acdb75fd1f9a8e0cd36a5 fix Issue 14799 - Documentation for std.zlib.compress is incorrect https://github.com/D-Programming-Language/phobos/commit/5f165ae4eeac55b909ab2a10feda1434c7c40b74 Merge pull request #3618 from CyberShadow/pull-20150901-053959