Join the discussion

Write your take first — we'll ask for email only when you're ready to publish.

  • Hacker News
  • I know syntax does not REALLY matter, but Zig is just kind of subpar syntax wise. Its really verbose and picked weirdly from what already exists. Zig code is usually hard to read because it really noicy, and has weird things not existing in other languages without merit.
  • I'm shipping in Rust but any reason to do so in Zig ? What does it offer over Rust ? Something tangible benefit to end user or developer using ai assisted development ?
  • Just use C, these are well understood things 20 years ago.
  • The way Zig handles the transition between synchronous and asynchronous I/O without requiring a heavy runtime is a masterclass in systems design. I'm particularly interested in how this approach to blocking calls might simplify mobile development where thread-per-request isn't always feasible but async/await coloring remains a pain. Does this implementation handle thread pool exhaustion gracefully if a large number of 'threaded' tasks block simultaneously?
  • Cool writeup but... Signals are not some opaque or roundabout feature to do this. Signals are a thing for a reason and this is how it's implemented in any threaded I/O library I've read.
  • Oh man this finishes too early, I would want to read more!
  • All my days of low level stuff were in the windows world where async/cancel was supported since nt kernel days at least. Wrapping this coherently at some level of abstraction was always worth doing, although threads are just one way. Overlapped I/O let you do it all on one thread. Linux looks harder.

    Great that Zig is supporting this more “first class”; not strictly required, but looks useful.

  • Just here to say that Java as interruptible channels since the beginning of 2000.

    You can interrupt a blocking IO operation with either interrupt() or close().

    https://docs.oracle.com/en/java/javase/25/docs/api/java.base...

Explore Birbla archives

Zig’s Io.Threaded is neat · Birbla