Skip to content

Comments

std.Io: handle packed structs better#24454

Merged
andrewrk merged 2 commits intomasterfrom
packed-struct-streams
Jul 15, 2025
Merged

std.Io: handle packed structs better#24454
andrewrk merged 2 commits intomasterfrom
packed-struct-streams

Conversation

@andrewrk
Copy link
Member

Rather than having the endian-suffixed functions be the preferred ones the unsuffixed ones are the preferred ones and the tricky functions get a special suffix.

Makes packed structs read and written the same as integers.

closes #12960

andrewrk added 2 commits July 14, 2025 18:38
Rather than having the endian-suffixed functions be the preferred ones
the unsuffixed ones are the preferred ones and the tricky functions get
a special suffix.

Makes packed structs read and written the same as integers.

closes #12960
@andrewrk andrewrk enabled auto-merge July 15, 2025 01:44
@andrewrk andrewrk added breaking Implementing this issue could cause existing code to no longer compile or have different behavior. standard library This issue involves writing Zig code for the standard library. labels Jul 15, 2025
@andrewrk andrewrk merged commit a5dbb65 into master Jul 15, 2025
12 checks passed
@andrewrk andrewrk deleted the packed-struct-streams branch July 15, 2025 11:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

breaking Implementing this issue could cause existing code to no longer compile or have different behavior. standard library This issue involves writing Zig code for the standard library.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Disallow reader.readStruct for packed structs

1 participant