news
Programming Leftovers
-
Chris ☛ Tagged data in Haskell (SICP 2.4.2)
I have a copy of sicp, or as it is also known, The Wizard Book. This book is widely praised, but I can’t take the time to work my way through all of it. However, sometimes I jump into parts of it that look interesting. Today, we’ll see how to support multiple representations of data through tagging.
This article is written in Haskell throughout, but at the start it will look a lot like the Lisp code in sicp. I have intentionally tried to recreate the sicp solution as closely as possible, including dynamic typing and all. See the appendix if you’re curious how it works.
-
John D Cook ☛ Regular expressions that work “everywhere”
The most frustrating aspect of regular expressions is that implementations vary. Features supported in one tool may not be supported at all in another tool, or they may be supported with slightly different syntax.
I learned regular expressions in the context Perl, a maximalist regex environment. This led to frustration when features I expect to work are missing [1]. One way around this is to use Perl analogs of other tools, but this is very non-standard. I want to be able to send colleagues and clients code that works out of the box.
-
Andrew Nesbitt ☛ Sunsetting a Package Manager
Plenty of users remain: React Native still resolves its iOS dependencies through CocoaPods, the move to SPM is an active RFC rather than a finished path, and a long tail of apps will keep running pod install well after the freeze. A registry that stops accepting uploads still serves installs to everyone who already depends on it, and the CocoaPods maintainers are not the first team to manage that. Four registries have frozen or shut down before them: [...]
-
Aethrvmn ☛ supermarket
Another fact about supermarkets is that the clerk doesn’t own the (soft)ware. The (soft)ware is owned by the supermarket, and so the clerk is disentivised from being deeply invested in a specific project, and are ‘asked’ to refrain from imbuing a specific project with their own personal vision, curiosity, or ideology. The clerk therefore is a functionary, not an author, and is evaluated on reliability, neutrality, and compliance rather than drive, want, personality, etc. In essence then, being a clerk is a thankless, unpaid job, in contrast with being an author of a passion project, passion which tends to be suppressed in supermarkets, as passion diverges from normative operations.
-
Akseli Lahtinen ☛ Please keep code descriptions simple
So this is my plea, from pure accessibility standpoint, to keep commit messages, merge request descriptions and code comments clear, to the point, need-to-know basis. Do not explain what, but why. Usually the code itself is enough to tell rest of the story. If not, I will ask questions. That's why it's a review.
-
Perl / Raku
-
Perl ☛ 2026-06-17 [Older] Urgent PPC Summer 2026 Update!
-
Perl ☛ 2026-06-16 [Older] This week in PSC (229) | 2026-06-16
-
Perl ☛ 2026-06-16 [Older] ANNOUNCE: Perl.Wiki V 1.48, Mojo.Wiki V 1.19 etc
-
Dan Q ☛ What Was Matt Thinking?
Later, I even added parameter handling to allow the webmaster to specify a different set of digit images, and referrer detection so that it could track different sites: each got its own text file with its count in it! For a while, a dozen or so of my friends had my counter visible on their Geocities and Angelfire pages!
-
-
R / R-Script
-
Rlang ☛ Flowcharts that belong in the analysis pipeline
The figure above is the kind of chart I want Gmisc to make feel natural. It is still a grid graphic in R, but it has the visual grammar of a manuscript figure: grouped arms, side exclusions, count badges, phase labels, and arrows that do not need nudging after every text change.
Every figure in this post is generated by code, and the code is included below each image. They all share the same two-line preamble: [...]
-
-
Java/Golang
-
Niel Madden ☛ Java’s SSLContext protocol name is a footgun
This should be old news, but I keep seeing the same mistake crop up, so I thought I’d blog about it and spread awareness. In Java, if you want to configure TLS you generally start with an SSLContext. And you get an instance of this class by calling the static method SSLContext.getInstance("TLSv1.3"), specifying the version of the protocol you want to support. But typically a TLS connection supports other versions of the protocol, so what exactly does specifying “TLSv1.3” here mean? Probably not what you think it means…
-