RSSAmplifier

Blog

What Comes to Mind

Stuff, and more stuff

sdowney.orgRSS feed ↗10 posts

Latest posts

An Infix Backtick Operator for C++

I am working on a proposal to let any callable be written between two backticks as an infix binary operator: x `f` y means exactly f(x, y) . It is borrowed from Haskell, it desugars to an ordinary call, and I have it working in both Clang and GCC. This post is the announcement and the design tour. 1. The pitch in one line C++ lets you spell a handful of binary operations infix — a + b , a < b , a…

Refreshing a Stale Git Subtree

I write my WG21 papers with MPark/WG21 , a Pandoc-based framework I vendor into the paper repo as a git subtree. The framework had a major overhaul–the build system split apart, and Pandoc jumped from 2.18 to 3.9–and my copy was 98 commits behind. Worse, the subtree had drifted in two directions at once: real local patches for a TLS-intercepting corporate network, and a pile of pointless…

Moving Forward With Legacy Encodings

1. Abstract Reverse-parsing legacy multibyte text encodings — such as Shift_JIS, Big5, or GB18030 — using only local context is an unsolvable problem. Unlike UTF-8, which guarantees \(O(1)\) self-synchronization, legacy encodings have heavily overlapping lead and trail byte ranges. Consequently, even if you begin at a known, valid character boundary, computing the byte-width of the preceding…

Tailwind, Modus Themes, and the Blog Theming Workflow

I replaced the Foundation 6 theme on this blog with Tailwind CSS. The immediate motivation was a CSS conflict—Foundation's global code and kbd rules bled into org-mode source blocks—but the deeper reason is that Tailwind has the community and documentation that Foundation no longer does. This post documents the workflow: how the theme is structured, how syntax highlighting CSS connects Emacs to…

Surround With UUID

The question of why C++ is standardized through ISO comes up fairly often. This is what I came up with as an explanation the last time I tried to answer that. It's a radically oversimplified too long elevator pitch.

Why Standard Organizations

The question of why C++ is standardized through ISO comes up fairly often. This is what I came up with as an explanation the last time I tried to answer that. It's a radically oversimplified too long elevator pitch. "Why Standards Organizations" is actually a really good question, as is the related question of if C and C++ should move from ISO. Standards organizations exist because standards are…

The Sender Sub-Language

The paper The Sender Sub-Language by Vinnie Falco <vinnie.falco@gmail.com> and Mungo Gill <mungo.gill@me.com> makes extensive use of my work at https://github.com/steve-downey/sender-examples . The code is also the basis for my talk at C++Now 2023, Using the C++ Sender/Receiver Framework: Implement Control Flow for Async Processing . They present the code accurately and fairly, and I am very happy…

Building vcpkg dependencies with project toolchain

Making sure vcpkg delivers packages built with your toolchain is not hard, but much of the advice on the internet is flat wrong. You need to specify your toolchain both in your project and in the the vcpkg triplet . There's an airgap between your project and the dependency in vcpkg install . The CMake settings can't just flow through. 1. Toolchain is more than just the compiler Inside a link…

Substitution is Sometimes a Failure

Why are optional::transform and optional::and_then not constrained by invocable ? 1. Optional "Monadic" Interface Monadic operations for std::optional transform is the c++ spelling for map or fmap and_then is monadic bind for optional or_else is dual to and_then or_else also has: Constraints: F models invocable and T models {move,copy}_constructible . transform and and_then do not. They don't work…

Nikola Blog Infrastructure

I've migrated from WordPress to a static blog generator–Nikola. This is how it works. 1. Nikola Nikola is a static site generator written in python. It's mostly boring, which is a very good thing for software meant for use to be. Its home is https://getnikola.org and the source is on github at https://github.com/getnikola/nikola . It's many years old at this point, but not dead. The interesting…