Get the latest tech news

Zig's new CLI progress bar explained


New CLI Progress Bar Explained Sometimes, programming projects are too easy and boring. Sometimes, they're too hard, never ending or producing subpar results.

This past week I had the pleasure of completing a project that felt like maximum difficulty - only possible because I am at the top of my game, using a programming language designed for making perfect software. Before this feature was even merged into master branch, it led to discovery, diagnosis, and resolution of a subtle bug that has hidden in Zig's standard library child process spawning code for years. In most programming projects, a linear scan to find allocated objects is undesirable, however in this case 200 bytes for node parent indexes is practically free to iterate over since it's 4 cache lines total, and the only contention comes from actual updates that must be observed.

Get the Android app

Or read this on Hacker News

Read more on:

Photo of CLI

CLI

Photo of zig

zig

Photo of new CLI progress bar

new CLI progress bar

Related news:

News photo

Weaver: An ergonomic CLI parsing library for Roc lang

News photo

Show HN: I made a CLI tool to create web extensions with no build configuration

News photo

Memory-mapped IO registers in Zig. (2021)