...and people wonder why software gets slower and bigger over time while doing the same thing. We even get HN articles about that semi-regularly.
...and people wonder why software gets slower and bigger over time while doing the same thing. We even get HN articles about that semi-regularly.
The amount of increase is irrelevant if it continues in the same direction.
Pretty much everything else in the C++ standard library is template code in headers and gets instantiated when needed. You may end up having identical templated functions emitted into several different translation units and the linker will chose one at link time, which is one major reason why C++ is slower to build.
Only template functions that are actually used get instantiated. If you include a header with a gazillion templated functions (namespace level or member functions, it doesn't matter) you are most likely to end up with only one or two instantiated in your binary. Templates are like a cookbook, and just because Larousse has 10,000 recipes does not mean that's how much you're going to eat at every meal. Consider there is virtually an infinite number of possible instantiations for every template.
Edit: libcxx from Chromium, not libstdc++
https://github.com/microsoft/vscode/pull/129360#issue-952350...
> The increase in bundle size is significantly small (~10MB).
That's not material.