Articles & Books

An Improved Thread with C++20--Rainer Grimm

More about c++20.

An Improved Thread with C++20

by Rainer Grimm

From the article:

std::jthread stands for joining thread. In addition to std::thread (C++11), std::jthread automatically joins in its destructor and can cooperatively be interrupted. Read in this post to know why std::jthread should be your first choice...

Colony – A brief history of timing--Matt Bentley

A different container.

Colony – A brief history of timing

by Matt Bentley

From the article:

Back in 2014 I began designing a game engine. Experienced programmers and curmudgeonly lecturers will tell you that if you make a game engine, you’ll never make a game – which is true, but sort of irrelevant. You will learn so much from making a game engine, you probably won’t care about the game by the end of it. The main reason I wanted to develop a game engine was that I was tired of seeing very basic 2D games with incredibly bad performance even on fast computers. If we got 15 frames-per-second on Intel 386 processors in the 1990s, why was it so hard for modern 2D games to achieve the same speed on exponentially-better hardware?

Overload 161 is now available

ACCU’s Overload journal of February 2021 is out. It contains the following C++ related articles.

Overload 161 is now available

From the journal:

In. Sub. Ordinate.
By Frances Buontempo
Mindless rebellion is mindless. Frances Buontempo encourages mindful consideration of when to refuse.

A Case Against Blind Use of C++ Parallel Algorithms
By Lucian Radu Teodorescu
C++17 introduced parallel algorithms. Lucian Radu Teodorescu reminds us we need to think when we use them.

C++ – an Invisible Foundation of Everything
By Bjarne Stroustrup
What is C++ and why do people still use it? Bjarne Stroustrup provides a short note answering these questions.

Test Precisely and Concretely
By Kevlin Henney
Tests can hit complete coverage but fail to communicate. Kevlin Henney reminds us that assertions should be necessary, sufficient, and comprehensible.

Afterwood
By Chris Oldwood
Think you’ve learnt it all? Chris Oldwood reminds us that unlearning then becomes our next problem.

Book “Beginning C++20”--Marc Gregoire

Another book.

Book “Beginning C++20”

by Marc Gregoire

From the article:

My friend Peter Van Weert finished a new edition of “Beginning C++20” for which I was technical editor. It’s a great book to learn C++20 for programmers new to C++ and those who may be looking for a refresh primer on C++ in general...

GotW #99 Solution: Postconditions -- Herb Sutter

Solution just posted:

GotW #99 Solution: Postconditions

by Herb Sutter

From the article:

Postconditions are directly related to assertions (see GotW #97)... but how, exactly? And since we can already write postconditions using assertions, why would having language support benefit us more for writing postconditions more than for writing (ordinary) assertions?

How std::any Works--Jonathan Boccara

Lambda magic.

How std::any Works

by Jonathan Boccara

From the article:

In the previous post we’ve seen a very nice technique to use value semantics with inheritance and virtual methods, which was made possible by std::any.

Given its usefulness, it would be interesting to better understand std::any. Indeed, std::any is sometimes said to be “the modern void*“. But it does much more than a void*...

12 Different Ways to Filter Containers in Modern C++--Bartlomiej Filipek

Many ways.

12 Different Ways to Filter Containers in Modern C++

by Bartlomiej Filipek

From the article:

Do you know how many ways we can implement a filter function in C++?

While the problem is relatively easy to understand - take a container, copy elements that match a predicate and the return a new container - it’s good to exercise with the Standard Library and check a few ideas. We can also apply some Modern C++ techniques.

Let’s start!

6 years of weekly Meeting C++ Blogrolls!

Its now 6 years since Meeting C++ publishes a weekly blogroll for C++!

6 years of Meeting C++ Blogrolls

by Jens Weller

From the article:

Today 6 years ago the first weekly blogroll of Meeting C++ was released.

Since then it has been released on (most) Fridays, giving you a weekly overview of what happend in the C++ Blog scene and Videos in the past 7 days. Since last year...