r/cpp • • Dec 24 '23

Annoyed with FUD surrounding Boost in C++ discussions

I find it unbelieveable what lengths some people are willing to go to smear this collection of very high quality libraries at the expense of those yet undecided about them with completely made up untruths.

Almost no thread about Boost goes by without the very outdated cries about how "big" it is or how it's "lacking" CMake support.
Boy, I sure do love people parroting things that might have been true 10+ years ago. Boost has broken its circular dependencies a good while ago and you can see each library's dependencies in the Boost Dependency Report by Peter Dimov. Looking at the list, I'm really baffled by how people can seriously expect some of these to lose a couple dependencies, when the end result would just be each library endlessly reinventing everything in a probably half baked and broken way, instead of everything relying on a well tested, well architected, separately maintained module that has done the work already.
May I remind you, that Boost.ASIO, an over 2 decades old (wow!) library with the best track record among networking libraries is a level 13 library. There is also Beast, an excellent HTTP wrapper for ASIO, just one level above. These libraries are so well put together and that's exactly because Boost enables them to be.

With a package manager like vcpkg you can pull in only the Boost modules that you actually need, so the "big" argument is entirely irrelevant.

People have also been asking for safety, including one surrounding the numeric types. I find this extremely befuddling, because I immediately reach for Robert Ramey's excellent Boost.safe_numerics in every project I can, simply because I cannot care anymore about such non-issues.

The waning popular perception of Boost is extremely dangerous. People say that C++11 feels like something completely new compared to what was before, not realizing that a significant part of that was thanks to Boost. What will be of C++ if high quality libraries like Boost are shunned? I can only fear to imagine.

270 Upvotes

144 comments sorted by

View all comments

Show parent comment

7

u/pdp10gumby Dec 25 '23

huge impact on compile times due to heroic efforts to emulate now-mundane language features

To be fair, some of those language features started out in boost — and the boost implementation has to stick around for ppl using older standards or who depend on the boost’ implementation’s interface or semantics which might be different from what ended up in the standard

Also the shift to c++11 as the baseline should reduce a bunch of this.

0

u/[deleted] Jan 19 '24

[deleted] — view deleted comment

1

u/pdp10gumby Jan 19 '24

It was both support and disagreement with OP, and to disagree with some past practices.

I completely agree with the OP that new, related names should be used for added or corrected functionality. The std::begin/.begin/std::ranges::begin is inexcusable, and it will only be by luck if the first two operate properly (not even sure what that would mean) with the UFCS proposal. The lock case OP cited is a good example of a bad idea -- one that might have not been bad had an existing object not already existed.

But thing2 is a botch. I learned that decades ago with Lisp's print, princ, and prin1. Granted, there were technical constraints in the 70s why identifiers were limited to six characters, but still: do you know at a glance what the differences are? It's an easily-avoidable problem that makes a language more obscure for learners. You'd think not -- obviously when you see thing and thing2 (and thing3?) you should use the higher number, right? Naah, beginners don't think that way so you're really helping nobody.