A developer blog run by 0xmote. Most posts are about C++ systems and network programming;
the rest cover backend, databases, DevOps, and media streaming problems I have had to solve.
Code examples are run before they are published, and every post shows when it was written and last updated.
About this blog · All posts
C++20 designated initializers: declaration-order rules, what C allows that C++ rejects, real GCC errors, defaults, nested structs and config-struct patterns.
From C++ source to executable: preprocessing, compilation, assembly, and linking, plus the link errors each stage causes (library order, templates, extern "C", ABI mismatches), rpath, LTO, and how C++20 modules change the pipeline.
How std::next_permutation works, why you sort first, how duplicates are handled, correct k-permutation and nCk loops, ranges versions and the k-th permutation.
How CMake find_package really searches: MODULE-then-CONFIG order, CMAKE_PREFIX_PATH and <Pkg>_ROOT, imported targets, FindBoost removal, and fixes for each error.
C++20 concepts and requires: the four constraint syntaxes, standard concepts, subsumption, real GCC/Clang errors and fixes, and migrating off enable_if.
Strongly typed scoped enums in C++11 and later: no implicit int conversion, explicit underlying types, switch exhaustiveness warnings that actually fire, type-safe bit flags, and keeping stored enum values stable.
A deep dive into C++ RAII grounded in a real production connection-leak incident, covering exception safety, the C++ Core Guidelines, and composable ownership.
std::shared_ptr reference counting, control blocks, weak_ptr observers, cycles, enable_shared_from_this, aliasing, custom deleters, and production patterns in modern C++.
When to use static_cast, dynamic_cast, const_cast and reinterpret_cast, what each checks, the undefined behavior they hide, and where std::bit_cast fits.
What ES2024 really added: Object.groupBy and Map.groupBy, Promise.withResolvers, resizable ArrayBuffer and transfer, well-formed strings and the RegExp v flag.