External Polymorphism in C++26
While developing our Type Erasure library Any++ for C++23, we had to resort to a preprocessor-based EDSL to eliminate the boilerplate.
By studying the "C++26 Reflection Proposals," I was constantly searching for a way to replace this preprocessor programming.
Implementing Type Erasure requires three components:
- A "V-Table" for indirecting function calls.
- A "Facade" for the ergonomic connection between the data and the "V-Table."
- An "Adapter" to connect the functions of the "V-Table" to the specific type.
It suffices to describe one of these components. The other two can then be generated automatically.
One way to do this with C++26 is to specify in code the default adapter and generate the V-table and facade.
C++26 allows you to generate a class using
The key is that the class can only contain data members.
However, since a data member can have an
These data members can be specified so that they don't occupy any memory. This allows you to access the enclosing class in the
Interestingly, this method also enables static dispatch with an elegant interface.
To coincide with the GCC16 release and its excellent reflection implementation, I've sketched out such an API:
Compiler Explorer
This is, of course, just a rough outline. The real value of a type erasure library lies in providing additional runtime capabilities (downcast, crosscast), lifetime mechanisms (shared, unique, value, etc.), and constant correctness.
Any++ provides all of this. As soon as Clang and MSVC also offer reflection, I will implement the presentated technique there.
For now, I have to thank the wizards who created this technical marvel: "C++ compile-time reflection"!
https://redd.it/1t14dw4
@r_cpp
While developing our Type Erasure library Any++ for C++23, we had to resort to a preprocessor-based EDSL to eliminate the boilerplate.
By studying the "C++26 Reflection Proposals," I was constantly searching for a way to replace this preprocessor programming.
Implementing Type Erasure requires three components:
- A "V-Table" for indirecting function calls.
- A "Facade" for the ergonomic connection between the data and the "V-Table."
- An "Adapter" to connect the functions of the "V-Table" to the specific type.
It suffices to describe one of these components. The other two can then be generated automatically.
One way to do this with C++26 is to specify in code the default adapter and generate the V-table and facade.
C++26 allows you to generate a class using
define_aggregate.The key is that the class can only contain data members.
However, since a data member can have an
operator(), member functions can also be simulated this way.These data members can be specified so that they don't occupy any memory. This allows you to access the enclosing class in the
operator() and use the information it manages (the V-table and the data reference).Interestingly, this method also enables static dispatch with an elegant interface.
To coincide with the GCC16 release and its excellent reflection implementation, I've sketched out such an API:
template <typename Self>
struct stringable{
[[=default_{}]] // that says: when not specialized, call self.as_string()
static std::string as_string(Self const& self);
};
void print(std::vector<dyn<stringable>> const& things){
for(auto& thing : things){
std::println("{}", thing.as_string());
}
}
template <>
struct stringable<int>{
static std::string as_string(int const& self) {
return std::to_string(self);
}
};
template <>
struct stringable<std::string>{
static std::string as_string(std::string const& self) {
return self;
}
};
struct foo{ double f; };
template <>
struct stringable<foo>{
static std::string as_string(foo const& self){
return "foo: " + std::to_string(self.f);
}
};
struct boo {
bool b = false;
std::string as_string(){
return std::string{"boo? "} + (b ? "T" : "F");
}
};
int main(int argc, char *argv[]) {
// static dispatch
auto a1 = trait_as<int, stringable>{{42}};
auto z_from_self = a1.as_string();
std::println("z_from_trait = {}", z_from_self);
// dynamic dispatch, reference semantics only
int i = 4711;
auto dyn_stringable = dyn<stringable>{i};
auto z_from_dyn_stringable = dyn_stringable.as_string();
std::println("z_from_dyn_stringable = {}", z_from_dyn_stringable);
std::string s = "hello world";
foo a_foo{3.14};
boo a_boo{true};
print({dyn<stringable>{i}, dyn<stringable>{s}, dyn<stringable>{a_foo}, dyn<stringable>{a_boo}});
}
Compiler Explorer
This is, of course, just a rough outline. The real value of a type erasure library lies in providing additional runtime capabilities (downcast, crosscast), lifetime mechanisms (shared, unique, value, etc.), and constant correctness.
Any++ provides all of this. As soon as Clang and MSVC also offer reflection, I will implement the presentated technique there.
For now, I have to thank the wizards who created this technical marvel: "C++ compile-time reflection"!
https://redd.it/1t14dw4
@r_cpp
GitHub
GitHub - bitfactory-software/anyxx: C++ vocabulary for programming on a large scale
C++ vocabulary for programming on a large scale. Contribute to bitfactory-software/anyxx development by creating an account on GitHub.
Microsoft ODBC Driver 17.11.1 for SQL Server released
ODBC Driver 17.11.1 is out.
Fixes:
Parameter array processing: SQL\_ATTR\_PARAMS\_PROCESSED\_PTR now reports correctly, row counting fixed when SQL\_PARAM\_IGNORE is used
Connection error with Data Classification metadata in async mode
XA recovery transaction ID computation
RPM side-by-side installs now work
Debian package license acceptance
New platforms:
macOS 14, 15, 26
Debian 13
RHEL 10
Oracle Linux 9, 10
SUSE 16
Ubuntu 24.04, 25.10
Alpine 3.21, 3.22, 3.23
Download: https://learn.microsoft.com/en-us/sql/connect/odbc/download-odbc-driver-for-sql-server
Full blog post: Microsoft ODBC Driver 17.11.1 for SQL Server Released | Microsoft Community Hub
https://redd.it/1t15ffy
@r_cpp
ODBC Driver 17.11.1 is out.
Fixes:
Parameter array processing: SQL\_ATTR\_PARAMS\_PROCESSED\_PTR now reports correctly, row counting fixed when SQL\_PARAM\_IGNORE is used
Connection error with Data Classification metadata in async mode
XA recovery transaction ID computation
RPM side-by-side installs now work
Debian package license acceptance
New platforms:
macOS 14, 15, 26
Debian 13
RHEL 10
Oracle Linux 9, 10
SUSE 16
Ubuntu 24.04, 25.10
Alpine 3.21, 3.22, 3.23
Download: https://learn.microsoft.com/en-us/sql/connect/odbc/download-odbc-driver-for-sql-server
Full blog post: Microsoft ODBC Driver 17.11.1 for SQL Server Released | Microsoft Community Hub
https://redd.it/1t15ffy
@r_cpp
Docs
Download ODBC Driver for SQL Server - ODBC Driver for SQL Server
Download the Microsoft ODBC Driver for SQL Server to develop native-code applications that connect to SQL Server and Azure SQL Database.
The STL for Geometry: Thirty-Year Evolution of C++ Libraries
https://polydera.com/algorithms/the-stl-for-geometry
https://redd.it/1t19d0y
@r_cpp
https://polydera.com/algorithms/the-stl-for-geometry
https://redd.it/1t19d0y
@r_cpp
Polydera
The STL for Geometry: Thirty-Year Evolution of C++ Libraries · Polydera
VTK, CGAL, libigl, MeshLib, and what comes next. What the STL philosophy of separating algorithms from data looks like when applied to geometry: semantic ranges, composable policies, and parallel algorithms that operate on them.
Showcase/Request for Feedback Achieving 0.31ns Pathfinding on M1 for Search & Rescue Drones – Seeking advice on further optimization.]
Hi everyone,
I’m a student and student pilot from Vietnam, currently obsessed with combining Physics and C++ to solve real-world problems. My current project, H.A.L.O. Aegis, is a 600-700KB core designed for search-and-rescue drones operating in catastrophic environments (like collapsed buildings).
My goal was to create a "zero-latency" escape route identifier that can fit into the tiny L2 cache of embedded systems.
Current Specs:
Performance: \~0.326 ns per op on Apple M1 (measured via Google Benchmark).
Throughput: 3.0679G/s.
Memory Safety: Verified with AddressSanitizer (ASan).
The "Elephant in the room": Since I wanted to move fast on the rescue logic, I used AI to help generate some of the boilerplate and the bilingual interface (about 30-40% of the code). I manually hand-tuned the core physics-based logic to hit the sub-nanosecond mark.
Why I'm here: I’m planning to share this with NGOs like the Red Cross, but before I do, I want to make sure the code is truly "bulletproof."
Is my benchmarking methodology sound?
Are there any C++20 features I missed that could make this even more efficient for ARM64?
Please be kind—I'm still learning and I'm aware some of my internal comments might be messy (working on English-izing them!).
I'm ready for the "code review of a lifetime." If there’s anything not quite right, please let me know so I can fix it before it actually goes into a drone to save lives.
Project Link: https://github.com/Nguyenidkskibidi/halo-aegis-core
Thank you for your time and expertise!
https://redd.it/1t1h0do
@r_cpp
Hi everyone,
I’m a student and student pilot from Vietnam, currently obsessed with combining Physics and C++ to solve real-world problems. My current project, H.A.L.O. Aegis, is a 600-700KB core designed for search-and-rescue drones operating in catastrophic environments (like collapsed buildings).
My goal was to create a "zero-latency" escape route identifier that can fit into the tiny L2 cache of embedded systems.
Current Specs:
Performance: \~0.326 ns per op on Apple M1 (measured via Google Benchmark).
Throughput: 3.0679G/s.
Memory Safety: Verified with AddressSanitizer (ASan).
The "Elephant in the room": Since I wanted to move fast on the rescue logic, I used AI to help generate some of the boilerplate and the bilingual interface (about 30-40% of the code). I manually hand-tuned the core physics-based logic to hit the sub-nanosecond mark.
Why I'm here: I’m planning to share this with NGOs like the Red Cross, but before I do, I want to make sure the code is truly "bulletproof."
Is my benchmarking methodology sound?
Are there any C++20 features I missed that could make this even more efficient for ARM64?
Please be kind—I'm still learning and I'm aware some of my internal comments might be messy (working on English-izing them!).
I'm ready for the "code review of a lifetime." If there’s anything not quite right, please let me know so I can fix it before it actually goes into a drone to save lives.
Project Link: https://github.com/Nguyenidkskibidi/halo-aegis-core
Thank you for your time and expertise!
https://redd.it/1t1h0do
@r_cpp
GitHub
GitHub - Nguyenidkskibidi/halo-aegis-core: Sub-nanosecond 10-layer SIMD bitboard and JPS+ navigation engine for autonomous robotics.…
Sub-nanosecond 10-layer SIMD bitboard and JPS+ navigation engine for autonomous robotics. Engineered for extreme safety and zero-latency reaction in chaotic rescue missions across ARM NEON/SSE4 arc...
Read-Copy Update (RCU) API in C++26
https://people.kernel.org/paulmck/stupid-rcu-tricks-rcu-api-in-cpp26
https://redd.it/1t1gqwp
@r_cpp
https://people.kernel.org/paulmck/stupid-rcu-tricks-rcu-api-in-cpp26
https://redd.it/1t1gqwp
@r_cpp
paulmck
Stupid RCU Tricks: RCU API in C++26 — paulmck
RCU was accepted into C++26 a few years back, and C++26 should be coming out soon, this being 2026 and all. The specification may be fou...
CppCon 2025: Can Standard C++ Replace CUDA for GPU Acceleration? - Elmar Westphal
https://www.youtube.com/watch?v=EOvukoCyW7A
https://redd.it/1t1kopc
@r_cpp
https://www.youtube.com/watch?v=EOvukoCyW7A
https://redd.it/1t1kopc
@r_cpp
YouTube
Can Standard C++ Replace CUDA for GPU Acceleration? - Elmar Westphal - CppCon 2025
https://cppcon.org
---
Can Standard C++ Replace CUDA for GPU Acceleration? - Elmar Westphal - CppCon 2025
---
On top of the woes of multi-threaded programming itself, coding for GPUs used to be about dealing with kernels, separate memory domains, warps…
---
Can Standard C++ Replace CUDA for GPU Acceleration? - Elmar Westphal - CppCon 2025
---
On top of the woes of multi-threaded programming itself, coding for GPUs used to be about dealing with kernels, separate memory domains, warps…
Does anyone maintain an impl of the Chandler Carruth map API?
Lightning Talk (C++Now 2019, 8min): https://youtube.com/watch?v=kye4aD-KvTU
In 2019, Chandler presented the above talk describing a C++ map API. It's not compatible with the standard map types, but for greenfield projects I think it's an excellent choice.
I've considered implementing it myself, but hash tables are very subtle and finicky. I'd rather rely on a robust implementation.
Abseil has some excellent hash tables, but to my knowledge they do not support the small size/small buffer optimization. Chandler's hypothetical API does. Would be great to have the SIMD probing algorithm from Abseil implemented for an SSO map type.
https://redd.it/1t21nhu
@r_cpp
Lightning Talk (C++Now 2019, 8min): https://youtube.com/watch?v=kye4aD-KvTU
In 2019, Chandler presented the above talk describing a C++ map API. It's not compatible with the standard map types, but for greenfield projects I think it's an excellent choice.
I've considered implementing it myself, but hash tables are very subtle and finicky. I'd rather rely on a robust implementation.
Abseil has some excellent hash tables, but to my knowledge they do not support the small size/small buffer optimization. Chandler's hypothetical API does. Would be great to have the SIMD probing algorithm from Abseil implemented for an SSO map type.
https://redd.it/1t21nhu
@r_cpp
YouTube
C++Now 2019: Chandler Carruth “A clean and minimal map API”
https://cppnow.org
—
Lightning Talk
—
Presentation Slides, PDFs, Source Code and other presenter materials are available at: https://cppnow.org/history/2019/talks/
—
Videos Filmed & Edited by Bash Films: https://www.BashFilms.com
---
*--*
---
—
Lightning Talk
—
Presentation Slides, PDFs, Source Code and other presenter materials are available at: https://cppnow.org/history/2019/talks/
—
Videos Filmed & Edited by Bash Films: https://www.BashFilms.com
---
*--*
---
Post examples of using reflections in your projects
What the title says. I just want to see what interesting things people are using reflection for now that its in gcc. Thanks.
https://redd.it/1t25byx
@r_cpp
What the title says. I just want to see what interesting things people are using reflection for now that its in gcc. Thanks.
https://redd.it/1t25byx
@r_cpp
Reddit
From the cpp community on Reddit
Explore this post and more from the cpp community
oo-alloc: i made a comprehensive learning resource for allocators in C++
hi!
i made a memory allocation library/learning resource. i wanted to learn more about them and i couldn't find one comprehensive source of knowledge, so i decided that i'll make one of my own:\].
it currently has these basic allocator types: arena (linear), stack, pool, free list, free tree, tracking, buddy, slab.
i gave my best to describe everything clearly in the readme, also added svg diagrams (written in Typst, btw). i plan to implement a bucket/size-segregated free list allocator as well.
hoping anyone will find this resource useful!
https://github.com/nihiL7331/oo-alloc
https://redd.it/1t287xq
@r_cpp
hi!
i made a memory allocation library/learning resource. i wanted to learn more about them and i couldn't find one comprehensive source of knowledge, so i decided that i'll make one of my own:\].
it currently has these basic allocator types: arena (linear), stack, pool, free list, free tree, tracking, buddy, slab.
i gave my best to describe everything clearly in the readme, also added svg diagrams (written in Typst, btw). i plan to implement a bucket/size-segregated free list allocator as well.
hoping anyone will find this resource useful!
https://github.com/nihiL7331/oo-alloc
https://redd.it/1t287xq
@r_cpp
GitHub
GitHub - nihiL7331/oo-alloc: An object-oriented memory allocation library written in C++20.
An object-oriented memory allocation library written in C++20. - nihiL7331/oo-alloc
I made C++ coding problems where you build things like a mini Redis or a tiny interpreter — looking for feedback
I’ve been building a small platform with coding problems that are more “systems-style” rather than typical algorithm exercises.
The idea is to practice by building simplified versions of real components, but still in a problem format (input/output + tests).
Some examples:
* implement a Redis-like server (TCP + protocol parsing)
* build a tiny interpreter
* create a virtual filesystem
* write an expression evaluator
The problems are:
* runnable directly in the browser (no setup)
* open-ended (you decide design/architecture)
* supporting multi-file submissions
I’m trying to keep them doable in a few hours, not huge multi-day projects.
I’m curious what people here think:
* does this kind of problem feel useful for improving practical C++ skills?
* or would you prefer something more guided / closer to full projects?
Still early, so any feedback would be really helpful.
Link: [https://elitecode.pro/](https://elitecode.pro/)
https://redd.it/1t2941b
@r_cpp
I’ve been building a small platform with coding problems that are more “systems-style” rather than typical algorithm exercises.
The idea is to practice by building simplified versions of real components, but still in a problem format (input/output + tests).
Some examples:
* implement a Redis-like server (TCP + protocol parsing)
* build a tiny interpreter
* create a virtual filesystem
* write an expression evaluator
The problems are:
* runnable directly in the browser (no setup)
* open-ended (you decide design/architecture)
* supporting multi-file submissions
I’m trying to keep them doable in a few hours, not huge multi-day projects.
I’m curious what people here think:
* does this kind of problem feel useful for improving practical C++ skills?
* or would you prefer something more guided / closer to full projects?
Still early, so any feedback would be really helpful.
Link: [https://elitecode.pro/](https://elitecode.pro/)
https://redd.it/1t2941b
@r_cpp
EliteCode
EliteCode — Practice Real Systems Engineering Problems
A clean, focused environment for practicing software engineering. Implement rate limiters, caches, URL routers, and more — no toy problems.
When to actually use a set
https://dubeykartikay.com/posts/why-never-use-std-unordered-set/
https://redd.it/1t2im2j
@r_cpp
https://dubeykartikay.com/posts/why-never-use-std-unordered-set/
https://redd.it/1t2im2j
@r_cpp
Kartikay Dubey's Blog
Why You Should Never Use a set: C++ Memory Costs
A benchmark-backed look at why std::unordered_set can lose badly to bitsets and contiguous memory in hot C++ loops, and when a hash set is still the right tool.
Migrating a small C++ code base to C++26 (modules, import std and contracts)
https://jonastoth.github.io/posts/migrate_cxx26/
https://redd.it/1t2kkoh
@r_cpp
https://jonastoth.github.io/posts/migrate_cxx26/
https://redd.it/1t2kkoh
@r_cpp
jonastoth.github.io
Migrating a Toy Project to C++-26
C++26 is around, GCC-16 is released, lets see what the state of modules, contracts and the tooling ecosystem for C++ is right now.
I built a C++ integer-to-string library based on a new AVX-512 paper
I built a small C++ integer-to-string conversion library based on a new paper by Jael Champagne Gareau and Daniel Lemire, "Converting an Integer to a Decimal String in Under Two Nanoseconds":
- Project: https://github.com/simditoa/simditoa
- Paper: https://arxiv.org/abs/2604.26019
The paper looks at decimal formatting for integers, which shows up in logging, JSON/CSV/XML serialization, database output, and other places where numbers eventually become text. The interesting part, and the part I wanted to experiment with, is that it uses AVX-512 IFMA instructions to extract multiple decimal digits in parallel, avoiding the usual repeated division/modulo loop and avoiding large lookup tables.
The library exposes a small
Current project shape:
- C++17
-
- AVX-512 IFMA + VBMI path for supported x86-64 CPUs
- portable scalar fallback
- CMake package/install support
- tests for edge cases, digit lengths, and randomized values
- a simple benchmark against
The README benchmark currently shows
The core trick is neat: for 8-digit chunks, it uses AVX-512 IFMA with precomputed constants based on
https://redd.it/1t2ny62
@r_cpp
I built a small C++ integer-to-string conversion library based on a new paper by Jael Champagne Gareau and Daniel Lemire, "Converting an Integer to a Decimal String in Under Two Nanoseconds":
- Project: https://github.com/simditoa/simditoa
- Paper: https://arxiv.org/abs/2604.26019
The paper looks at decimal formatting for integers, which shows up in logging, JSON/CSV/XML serialization, database output, and other places where numbers eventually become text. The interesting part, and the part I wanted to experiment with, is that it uses AVX-512 IFMA instructions to extract multiple decimal digits in parallel, avoiding the usual repeated division/modulo loop and avoiding large lookup tables.
The library exposes a small
to_chars-style API:#include "simditoa.h"
char buf[simditoa::MAX_DIGITS + 1];
size_t len = simditoa::to_chars(12345, buf);
buf[len] = '\0';
Current project shape:
- C++17
-
int64_t and uint64_t support- AVX-512 IFMA + VBMI path for supported x86-64 CPUs
- portable scalar fallback
- CMake package/install support
- tests for edge cases, digit lengths, and randomized values
- a simple benchmark against
std::to_charsThe README benchmark currently shows
simditoa::to_chars at about 15.82 ns/int versus 36.35 ns/int for std::to_chars on the tested setup, roughly 2.3x faster in that run. The paper reports stronger results for its full algorithm and benchmark suite, including single-core performance ahead of other tested methods, but my repo should be treated as a compact implementation based on the paper rather than a full reproduction of every variant in it.The core trick is neat: for 8-digit chunks, it uses AVX-512 IFMA with precomputed constants based on
floor(2^52 / 10^k) to compute digit positions in parallel, then gathers the digit bytes with AVX-512 byte permutation. Larger values are split into chunks.https://redd.it/1t2ny62
@r_cpp
GitHub
GitHub - simditoa/simditoa: SIMD-accelerated integer-to-string conversion
SIMD-accelerated integer-to-string conversion. Contribute to simditoa/simditoa development by creating an account on GitHub.
Auxid: An Orthodox C++20 Base Library for Data-Oriented Design
NOTE: All and any colorations/PRs are welcome, **EXCEPT FOR AI GENERATED GARBAGE**.
Hey folks,
Let me introduce Auxid: a C++20 platform/library aimed at high-performance applications (specifically game engines and systems software) built around **Orthodox C++** and **Data-Oriented Design (DOD)**.
I know the C++ ecosystem isn't short on utility libraries, but I built Auxid to bridge a specific gap: getting the predictable memory layouts and fast compile times of C-style systems programming, without losing the ergonomics of standard C++20 algorithms.
Mainstream C++ often relies on heavily templated, node-based STL containers that can thrash CPU caches or introduce hidden heap allocations. Auxid strips that back. Where the STL is already the right tool for the job (like `std::filesystem`), Auxid exposes it through thin, zero-overhead wrappers. For the rest, it provides DOD-friendly replacements.
Here’s a quick architectural overview of what’s inside:
* **Cache-Friendly Containers:** Includes a sparse-dense hash map, strictly aligned vector types, and small-string-optimized (SSO) strings.
* **Plays Nice with** `<algorithm>`: Auxid’s containers use iterators that satisfy C++20 iterator concepts (like contiguous iterators), meaning you can seamlessly pass them into `std::sort`, standard ranges, and other utilities.
* **Total Allocator Control:** No surprise allocations in the hot path. Auxid integrates [rpmalloc](https://github.com/mjansson/rpmalloc) out of the box for extremely fast, thread-caching heap allocation, alongside custom arena allocators.
* **Lightweight Error Handling:** Instead of exceptions, it relies on a union-based `Result<T, E>` and `Option<T>` that compile to tight representations, paired with Rust-style `AU_TRY` macros.
* **Explicit Control Flow:** Auxid provides an opt-in CMake target (`auxid_platform_standard`) that strictly disables C++ exceptions (`-fno-exceptions` / `/EHs-c-`) to enforce predictable performance characteristics.
It's designed to be dropped directly into existing CMake projects via `FetchContent`:
FetchContent_Declare(
auxid
GIT_REPOSITORY https://github.com/I-A-S/Auxid.git
GIT_TAG main
)
FetchContent_MakeAvailable(auxid)
If you are interested in DOD, alternative standard libraries, or just want to critique the architecture, I’d really value this community's feedback.
* **Core Library:** [I-A-S/Auxid](https://github.com/I-A-S/Auxid)
* **Project Scaffold:** [I-A-S/Auxid-Project-Template](https://github.com/I-A-S/Auxid-Project-Template)
Licensed under Apache 2.0.
Eager to hear what you think not just about the project, but the principles of Orthodox C++ as a whole!
https://redd.it/1t2nyai
@r_cpp
NOTE: All and any colorations/PRs are welcome, **EXCEPT FOR AI GENERATED GARBAGE**.
Hey folks,
Let me introduce Auxid: a C++20 platform/library aimed at high-performance applications (specifically game engines and systems software) built around **Orthodox C++** and **Data-Oriented Design (DOD)**.
I know the C++ ecosystem isn't short on utility libraries, but I built Auxid to bridge a specific gap: getting the predictable memory layouts and fast compile times of C-style systems programming, without losing the ergonomics of standard C++20 algorithms.
Mainstream C++ often relies on heavily templated, node-based STL containers that can thrash CPU caches or introduce hidden heap allocations. Auxid strips that back. Where the STL is already the right tool for the job (like `std::filesystem`), Auxid exposes it through thin, zero-overhead wrappers. For the rest, it provides DOD-friendly replacements.
Here’s a quick architectural overview of what’s inside:
* **Cache-Friendly Containers:** Includes a sparse-dense hash map, strictly aligned vector types, and small-string-optimized (SSO) strings.
* **Plays Nice with** `<algorithm>`: Auxid’s containers use iterators that satisfy C++20 iterator concepts (like contiguous iterators), meaning you can seamlessly pass them into `std::sort`, standard ranges, and other utilities.
* **Total Allocator Control:** No surprise allocations in the hot path. Auxid integrates [rpmalloc](https://github.com/mjansson/rpmalloc) out of the box for extremely fast, thread-caching heap allocation, alongside custom arena allocators.
* **Lightweight Error Handling:** Instead of exceptions, it relies on a union-based `Result<T, E>` and `Option<T>` that compile to tight representations, paired with Rust-style `AU_TRY` macros.
* **Explicit Control Flow:** Auxid provides an opt-in CMake target (`auxid_platform_standard`) that strictly disables C++ exceptions (`-fno-exceptions` / `/EHs-c-`) to enforce predictable performance characteristics.
It's designed to be dropped directly into existing CMake projects via `FetchContent`:
FetchContent_Declare(
auxid
GIT_REPOSITORY https://github.com/I-A-S/Auxid.git
GIT_TAG main
)
FetchContent_MakeAvailable(auxid)
If you are interested in DOD, alternative standard libraries, or just want to critique the architecture, I’d really value this community's feedback.
* **Core Library:** [I-A-S/Auxid](https://github.com/I-A-S/Auxid)
* **Project Scaffold:** [I-A-S/Auxid-Project-Template](https://github.com/I-A-S/Auxid-Project-Template)
Licensed under Apache 2.0.
Eager to hear what you think not just about the project, but the principles of Orthodox C++ as a whole!
https://redd.it/1t2nyai
@r_cpp
GitHub
GitHub - mjansson/rpmalloc: Public domain cross platform lock free thread caching 16-byte aligned memory allocator implemented…
Public domain cross platform lock free thread caching 16-byte aligned memory allocator implemented in C - mjansson/rpmalloc
GoodLog: a small C++17 wrapper around Boost.Log for colored output, rotation and hex dumps
Hi r/cpp,
I built GoodLog, a small C++17 wrapper around Boost.Log.
The goal is not to replace general-purpose logging libraries like spdlog. I wanted a reusable layer for C++ projects that already depend on Boost, so the common Boost.Log setup does not have to be repeated across modules.
It currently supports:
\- colored console output
\- automatic file:line source location
\- rotating log files
\- separate severity filters for console and file sinks
\- optional channel filtering
\- hex dump helpers for binary buffers
\- CMake demo and GoogleTest entry points
GitHub:
https://github.com/SoleyRan/Log
The project is still early, and I would especially appreciate feedback on the macro API, CMake integration, and whether the channel logging interface should be simplified.
https://redd.it/1t2pmyu
@r_cpp
Hi r/cpp,
I built GoodLog, a small C++17 wrapper around Boost.Log.
The goal is not to replace general-purpose logging libraries like spdlog. I wanted a reusable layer for C++ projects that already depend on Boost, so the common Boost.Log setup does not have to be repeated across modules.
It currently supports:
\- colored console output
\- automatic file:line source location
\- rotating log files
\- separate severity filters for console and file sinks
\- optional channel filtering
\- hex dump helpers for binary buffers
\- CMake demo and GoogleTest entry points
GitHub:
https://github.com/SoleyRan/Log
The project is still early, and I would especially appreciate feedback on the macro API, CMake integration, and whether the channel logging interface should be simplified.
https://redd.it/1t2pmyu
@r_cpp
GitHub
GitHub - SoleyRan/Log: A lightweight C++17 logging wrapper around Boost.Log with colored output, rotating files, severity filters…
A lightweight C++17 logging wrapper around Boost.Log with colored output, rotating files, severity filters, and hex dump helpers. - SoleyRan/Log