Archive for February, 2018

The joys of forward declarations: results from the real world

February 25, 2018

This is not what you want your dependency graph to look like (graph generated using

As a C++ project grows and matures, the following line is inevitably spoken: “The build is too slow”. It doesn’t really matter how long the build actually takes; it is just taking longer than it was. Things like this are an inevitability as the project grows in size and scope.

In this post I’ll talk specifically about my recent use of forward declarations to vastly improve build times on one of those projects, and how you can too.