joebaf
Parsing Numbers At Compile Time with C++17, C++23, and C++26
C++20, Spans, Threads and Fun
Re:Initialization in Modern C++ (295 pages)
on Tuesday March 28, 2023 @10:06AM (#35341318)
Here's the direct link to the blog post on the book:
https://www.cppstories.com/2023/init-story-print/
And the book at Leanpub:
Re:Combining Collections with Zip in C++23 for Efficient Data Processing
on Monday March 13, 2023 @04:45PM (#35142284)
Do you have more examples where zip is handy? I've noticed it's a quite common feature of other languages like Python...
Re:Std: Initializer_list in C++ 2/2 – Caveats and Improvements
on Monday February 13, 2023 @02:06PM (#34778523)
Do you us std::initializer list in your code?
Is is that bad? std:initializer_list in C++ 1/2 – Internals and Use Cases
Re:C++ at the End of 2022
on Monday January 02, 2023 @02:41AM (#34215386)
is ChatGPT actually the most important thing that happens... not just for C++, but in terms of all programming languages? How will it affect programming?
Re:C++ at the End of 2022
on Sunday January 01, 2023 @02:52PM (#34210121)
is ChatGPT actually the most important thing that happens... not just for C++, but in terms of all programming languages? How will it affect programming?
Structured bindings in C++17, 5 years later
Re:Const vs. constexpr vs. consteval vs. constinit in C++20
on Monday November 28, 2022 @01:59PM (#33777934)
on the other hand with more options you can express more and write safer code (for example with constinit which solves static order init fiasco...)
And if you don't have enough knowledge you can just stick to const.
What re alternatives for a system programming language? (Rust seems to be fine, but still it's not super easy...)
Const vs. constexpr vs. consteval vs. constinit in C++20
How to Measure String SSO Length with constinit and constexpr (C++20 experiment)
Summary of Non-Regular Data Members in C++
How to Improve or Avoid Loops in C++20 23
C++20: Reducing Signed and Unsigned Mismatches with Std:Ssize()
Integer Conversions and Safe Comparisons in C++20
How to Init a String, Looking for Sanity
Curious C++ Lambda Examples: Recursion, constexpr, Containers C++23 included
Simplify Code with if constexpr and Concepts in C++17/C++20 (updated for 2022)
Re:Custom types and std:format from C++20
on Tuesday July 26, 2022 @05:11AM (#32235987)
and std::print is already voted into C++23!
Custom types and std:format from C++20
Five tricky topics for data members in C++20
(Non) Static Data Members Initialization, from C++11 Till C++20
Re:C++ Templates: How to Iterate through std:tuple: std:apply and More
on Monday February 14, 2022 @02:17PM (#30336837)
Hi, Author here - I went to lambdas because I got some compilation issues... because some stupid mistakes the code with std::apply(printImpl<Args...>, tp) didn't compile...
But now I see the issue and it's improved. So the version:
template <typename... Args> void printTupleApplyFn(const std::tuple<Args...>& tp) { std::cout << "("; std::apply(printImpl<Args...>, tp); // << std::cout << ")"; }
is fine and probably the easiest
Re:How to Refactor new/delete into unique ptr
on Monday October 18, 2021 @01:27PM (#28908065)
Yep, smart pointers are essential for modern C++, and they provide improved security over raw pointers.
How do you use smart pointers? What’s your common use case to refactor into smart pointers?
Steps to Find the Source of a Bug Quickly
Re:C++20 Oxymoron: Constexpr Virtual
on Monday September 13, 2021 @08:12AM (#28510475)
Do you have any better use cases for those constexpr techniques? maybe we could make simpler code to CRTP?
Re:Constexpr vector and string in C++20 and One Big Limitation
on Monday August 30, 2021 @01:34PM (#28358426)
do you have any useful use cases for such expressions? computing values based on text config? generating lookup tables? something else?