News for hackers. Stuff that matters.
Re:Packed structs in Zig make bit/flag sets trivial by Comevius on Tuesday August 30, 2022 @07:10AM (#32648901)
You can do this and more in Zig. The only caveat is that for MMIO you need a volatile pointer.

https://www.scattered-thoughts.net/writing/mmio-in-zig/

It gets tricky if you need more control over loads and stores, or if there are different address spaces.

There are no comments on this comment yet.