Under the Hood

C++ & Python. Mechanisms, tradeoffs, and doors left open.

Test Post — C++ Code Rendering

This is a rendering test for C++ code blocks. Template-Heavy Code template <typename T> void swap(T& a, T& b) noexcept( std::is_nothrow_move_constructible_v<T> && std::is_nothrow_move_assignable_v<T>) { T tmp = std::move(a); a = std::move(b); b = std::move(tmp); } Nested Angle Brackets std::vector<std::pair<std::string, int>> entries; std::unordered_map<std::string, std::vector<int>> index; Inline Code in Prose When you call push_back() on a std::vector<int>, the capacity doubles from 8 to 16. The noexcept specifier on your move constructor determines whether std::vector will move or copy during reallocation. ...

March 12, 2026 · 1 min · Gracjan Olbinski