From 808fa0f7bd1837fa7ca812c6813574234afd1ad2 Mon Sep 17 00:00:00 2001 From: portersky Date: Mon, 5 Oct 2026 11:58:42 +0200 Subject: [PATCH] docs: add C++ scratchpad notes Collect new C++ features to cover, design patterns, and compiler options for catching undefined behavior. Co-authored-by: Qwen 3.8 27B --- notes/scratch.md | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 notes/scratch.md diff --git a/notes/scratch.md b/notes/scratch.md new file mode 100644 index 0000000..7490ea5 --- /dev/null +++ b/notes/scratch.md @@ -0,0 +1,19 @@ +# C++ Scratchpad + +## New features in C++ + +- 23 and 26 +- r-value (and the values that I forgor) + +## Patterns + +- CRTP + +## compiler options that make undefined an error + +- -fsanitize=undefined +- chk_add(), chkd_sub(), chkd_mul() +- non-portable ways to check CPU overflow + - msvc intsafe.h + +## Design Patterns