RSSAmplifier

Blog

matklad

matklad s Arts&Crafts

matklad.github.ioRSS feed ↗10 posts

Latest posts

Printing Lists

To print a comma-separated list, a concise idiom is to optionally print the comma first, before the element:

Zig's Io.Threaded is Neat

std.Io.Threaded is one of the implementations of Zig's new Io interface that enables concurrency. This is a boring just use threads impl. I personally find it neat though --- it does this weird thing that I wanted to do for ages, that to my knowledge no one else is doing properly, and implements it better than I thought to be possible.

Memory Safety's Hardest Problem

Uplifting a lobsters comment for easier reference.

CSS: Unavoidable Bad Parts

An ersatz CSS tutorial for people who need to style a web page, but aren't web developers. I am a wrong person to write this kind of thing, as I have neither the time, nor experience. I'd much rather read a book about this. Alas, I had to learn all this stuff from trawling MDN, so perhaps it is valuable to document what I have so far.

TIL: Symlinking NixOS Dotfiles

The standard answer to managing dotfiles on NixOS is home-manager. I've never used it, due to two aesthetic and one practical objection:

Always Be Blaming

A few tips on 4D-ing your code comprehension skills.

Catch Flakes On Main

A small Mechanical Habit today:

Learning Software Architecture

In reply to an email asking about learning software design skills as a researcher physicist:

Steering Zig Fmt

Two tips on using zig fmt effectively. Read this if you are writing Zig, or if you are implementing a code formatter.

Minimal Viable Zig Error Contexts

Out of the box, Zig provides minimal and sufficient facilities for error handling --- strongly-typed error codes. Error reporting is left to the user. Idiomatic solution is to pass a Diagnostics out parameter (sink) to materialize human-readable strings as needed.