Last year, upon an unintentional nerd snipe from a friend, I spent a weekend writing a pretty performant XML library in Jai. In order to make sure it handled things correctly I used the XML 1.1 test suite as conformance tests, even though realistically it consists to a very large degree of tests of weird encodings and bizarre edge cases. I got most of it done, but for the last year I’ve had this weirdly deep sense of guilt over not having finished adding support for UTF-16.
My reading list of 2024 is marked by not having had much time to read, or rather, my reading being mostly in the form of code and papers. But here’s the list.
It’s not quite in the right order, because some of these I started last year and finished this year (similarly, books I’ve started but haven’t finished aren’t on this list). I’ve tried to put a tiny review with each one, but it’s not quite intentful enough to be actual reviews.
I’ve been programming for long enough to be righteously cantankerous about a lot of things. The list of languages, frameworks and libraries I’ve worked with professionally or on personal projects is too long to list – but it includes everything from C and assembly languages through C++, Pascal and Delphi, through Java and Clojure, through Perl, PHP, Python, Javascript, Typescript and so on. I’ve tinkered with Rust, APL, Uiua, Erlang and Haskell.
It’s election season here in Iceland! The election is on Saturday, 30th of November, so next Saturday from when this is written.
Every time elections are upcoming, somebody inevitably asks me how the voting system here works, probably expecting a simple answer. So, here’s a stab at it.
Iceland uses a biproportional apportionment system, as do Norway, some cantons of Switzerland, some German regions, and a few other places. Such systems have a few general features:
Israel has begun its second land war of the last 12 months by invading Lebanon. Having leveled most of Gaza to the ground with 60% of housing damaged, 65% of croplands destroyed; having killed over 42 thousand civilans in Palestine, with another ten thousand missing and over 100 thousand injured; having rendered Palestine incapable of sustaining life without outside support, which has been kept to a trickle, Israel is now escalating in other directions.
2024 was the year I transitioned back into nearly full-time professional vagrancy, although I still maintain a default home base in Iceland for now. I’ve not been very actively writing on this blog this year. I keep feeling guilty about that, but I’ve really been quite busy with other stuff, mostly working on building EarthOS. I’ve also traveled a lot this year - Curaçao, Miami, Malaga, London, Malta, Kentucky, Indiana, West Virginia, New York, Pennsylvania, Tennessee, North Carolina, Washington DC, Iceland, Croatia, Ireland, Bosnia & Herzegovina… I’m probably forgetting something.
Okay, so, I ranted a bit on YouTube. Oops. Here’s an accompanying longread, to waste even more of your life.
Here’s the TLDR(oW) version: JSON is a ubiquitous structured data format, used for both data storage and exchange. But it’s slow, and what’s worse, it’s dangerous. We should use other formats, probably MessagePack.
JSON is a weird accident of history. It grew out of Douglas Crockford’s need to be able to send messages between server and browser.
For years, graphical widget sets, or UI toolkits, or whatever you want to call them, have sucked.
They suck for a wide variety of reasons, but broadly speaking there are a few classes of problems that UI toolkits fail at some or all of:
Platform specificity: They don’t work on all platforms. Language specificity: They’re written in a language that is either difficult to make bindings for (like C++, because name mangling), or is interpreted, making binding to it undesirable if not practically impossible.
In mid-December, I left Iceland. Not forever, not exactly on vacation either. Not with a concrete plan, but a loose one. Flexible to my needs and desires.
Basically, being in Iceland was getting to me. Between the cold and the darkness, and the feeling that I had somehow gotten into an unhealthy pattern of working too much and my only non-work activities being socializing with alcohol or playing the occasional game.
XML is, as formats go, terrible.
If we think about what it’s doing, it’s outlining a hierarchy of nested nodes, each of which can have a number of attributes. Nodes can additionally contain CDATA or PCDATA, which practically speaking are typically treated as their own nodes. A few magic nodes exist, mostly for compatability with SGML.
It’s a tree. There are lots of other ways of describing trees textually. Some are bad, some are good.