ziglang/ziglang.org
14
29
Fork
You've already forked ziglang.org
31

0.15.1 release notes: fix std.compress.flate code snippet #568

Open
generalmimon wants to merge 1 commit from generalmimon/fix-code-snippet-in-0.15.1-relnotes into main
pull from: generalmimon/fix-code-snippet-in-0.15.1-relnotes
merge into: ziglang:main
ziglang:main
ziglang:release-0.16.0
ziglang:apraga/french
ziglang:homersimpsons/fix/mobile-responsiveness
ziglang:MarkLagodych/patch-1
ziglang:Zirunis/patch-1
ziglang:zmitchell/zmitchell/build-graph-docs
ziglang:generalmimon/fix-unit-testing-examples
ziglang:TheConnorJohnson/main
ziglang:meeting-minutes
ziglang:enkvadrat/update-curl-example
generalmimon commented 2025年11月13日 22:42:53 +01:00 (Migrated from github.com)
Copy link

streamRemaining is a method of std.Io.Reader (see https://ziglang.org/documentation/0.15.1/std/#std.Io.Reader.streamRemaining), not std.compress.flate.Decompress.

FWIW, I encountered this error when I tried to use std.compress.flate.Decompress in combination with streamRemaining in my code. Here's the final code that works on Zig 0.15.2: github.com/kaitai-io/kaitai_struct_zig_runtime@d0aee404b6/src/root.zig (L519-L526)

`streamRemaining` is a method of `std.Io.Reader` (see https://ziglang.org/documentation/0.15.1/std/#std.Io.Reader.streamRemaining), not `std.compress.flate.Decompress`. FWIW, I encountered this error when I tried to use `std.compress.flate.Decompress` in combination with `streamRemaining` in my code. Here's the final code that works on Zig 0.15.2: https://github.com/kaitai-io/kaitai_struct_zig_runtime/blob/d0aee404b6f3a8584ce4df57c52ce0425dc2ab8e/src/root.zig#L519-L526
alexrp force-pushed generalmimon/fix-code-snippet-in-0.15.1-relnotes from 7d2d63bd56 to a62d43a9c0
All checks were successful
test website / build (pull_request) Successful in 2m39s
2026年03月15日 22:30:25 +01:00
Compare
All checks were successful
test website / build (pull_request) Successful in 2m39s
Required
Details
This pull request can be merged automatically.
This branch is out-of-date with the base branch
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin generalmimon/fix-code-snippet-in-0.15.1-relnotes:generalmimon/fix-code-snippet-in-0.15.1-relnotes
git switch generalmimon/fix-code-snippet-in-0.15.1-relnotes
Sign in to join this conversation.
No reviewers
Labels
Clear labels
bounty
https://ziglang.org/news/announcing-donor-bounties
bug
Observed behavior contradicts documented or intended behavior.
contributor-friendly
This issue is limited in scope and/or knowledge of project internals.
downstream
An issue with a third-party project that uses this project.
enhancement
Solving this issue will likely involve adding new logic or components to the codebase.
infra
An issue related to project infrastructure, e.g. continuous integration.
optimization
A task to improve performance and/or resource usage.
question
No questions on the issue tracker; use a community space instead.
regression
Something that used to work in a previous version stopped working
upstream
An issue with a third-party project that this project uses.
use case
Describes a real use case that is difficult or impossible, but does not propose a solution.
Milestone
Clear milestone
No items
No milestone
Projects
Clear projects
No items
No project
Assignees
Clear assignees
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
ziglang/ziglang.org!568
Reference in a new issue
ziglang/ziglang.org
No description provided.
Delete branch "generalmimon/fix-code-snippet-in-0.15.1-relnotes"

Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?