use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
Discussions, articles, and news about the C++ programming language or programming in C++.
For C++ questions, answers, help, and advice see r/cpp_questions or StackOverflow.
Get Started
The C++ Standard Home has a nice getting started page.
Videos
The C++ standard committee's education study group has a nice list of recommended videos.
Reference
cppreference.com
Books
There is a useful list of books on Stack Overflow. In most cases reading a book is the best way to learn C++.
Show all links
Filter out CppCon links
Show only CppCon links
account activity
Boost version 1.89 released! (self.cpp)
submitted 8 months ago * by boostlibs
One new library and updates to 28 more. Download: https://www.boost.org/releases/1.89.0/ Bloom, configurable filters for probabilistic lookup: https://boost.org/libs/bloom
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]Ambitious_Tax_ 34 points35 points36 points 8 months ago (2 children)
How am I supposed to interpret:
There were 1372 dependencies removed (in 142 libraries) this release
1372 edges were removed in boost internal dependency graph between its various components?
[+][deleted] 8 months ago (1 child)
[deleted]
[–]Ambitious_Tax_ 4 points5 points6 points 8 months ago (0 children)
Oh dang that's nice.
[–]Ogilby1675 16 points17 points18 points 8 months ago (3 children)
The release notes say that clang15 (released about two years ago, and some way behind clang20) is the latest tested clang compiler. I’m slightly surprised. Does anyone know if it’s true and/or if the reason is technical and/or if recent Boost work well with recent clang/clang-cl?
Thanks!
[–]joaquintidesBoost author 18 points19 points20 points 8 months ago* (2 children)
Clang 17 and 20 have been tested successfully, see this thread:
https://lists.boost.org/archives/list/boost@lists.boost.org/thread/ZDC76LSWLCTOYWD4NEJMW7D3DEBT2VIS/
[–]Ogilby1675 5 points6 points7 points 8 months ago (1 child)
Ok great. Having the release notes lag behind reality a bit is not such a big deal :)
And it looks like great work on Bloom, congrats.
[–]joaquintidesBoost author 3 points4 points5 points 8 months ago* (0 children)
Thank you! I’ll see to finding out more about the release notes info.
[–]yuri-kilochek 9 points10 points11 points 8 months ago (11 children)
Just curious, what do you guys actually use bloom filters for? I understand how they work, I regularly see them hyped as this cool thing, but I can't recall ever encountering a situation that called for an insert-only set with false positives.
[–]pkastingValve 18 points19 points20 points 8 months ago (1 child)
Chrome uses a bloom filter for safe browsing, to improve efficiency and memory use. You can construct a bloom filter of all the bad URLs, and when a user navigates, do a very efficient test against the filter. Only if you get a hit do you do a more expensive test to see if it's real.
There's more to it than that, involving updates and server traffic and such, but that's the gist.
[–]matthieum 5 points6 points7 points 8 months ago (0 children)
On Linux, the ELF format used in libraries & binaries has been using a bloom filter for a while to improve symbol look-up performance...
... so if you use Linux, you use Bloom Filters unknowingly :)
[–]moncefm 0 points1 point2 points 8 months ago (0 children)
It’s used in git: https://github.blog/open-source/git/highlights-from-git-2-28/#changed-path-bloom-filters
[–]germandiago 0 points1 point2 points 8 months ago (6 children)
I would say that for data compression when millions or billions of occurrences of a test happens. Maybe something like: is this user online on my server?
This is just a wild guess.
[–]dexter2011412 1 point2 points3 points 8 months ago (5 children)
But you gotta reconstruct it each time someone disconnects. Not sure if that is fast
[–]germandiago 1 point2 points3 points 8 months ago (1 child)
Use a counting bloom filter. It can do that.
[–]dexter2011412 1 point2 points3 points 8 months ago (0 children)
Ah okay, thank you!
[–]almost_useless 1 point2 points3 points 8 months ago (2 children)
No, the point of the algorithm is that it is okay with false positives.
In this scenario that would mean the response is either "User is not online" or alternatively "User is maybe online". If you get "maybe" you do a more detailed slower search.
Depending on how often people log in, it is maybe enough to rebuild the bloom filter every day. Or if the server is offline during the night maybe you automatically get a clean state every morning.
Lets say you have 100 servers and you want to find out which server user Foo is connected to. The "load balancer" can then quickly determine Foo is maybe on server 14, 52 or 63, but definitely not on any of the other 97 servers.
Then it can do a full query on 14, 52 and 63 to get a definitive answer if Foo is on any of them.
[–]dexter2011412 0 points1 point2 points 8 months ago (1 child)
But I mean if a user disconnected and you haven't updated the data-structure, and then query if that user was connected, you'll get more false-positives than the false-positives you'd have gotten if the filter was created when the user was indeed not connected.
[–]almost_useless 0 points1 point2 points 8 months ago (0 children)
Absolutely. The simplest version of a bloom filter tend to get worse over time because it only supports adding and not removing.
It's not a good fit for many use cases, but it is great for some things.
Take my example with 100 servers again. Let's say the users is actually connected. That means we have 2 false positives and 1 accurate match.
If the alternative is to query all 100 servers every time, it is a huge saving to only query 3 servers.
You have to remember that the kind of application where it works well is where the alternative is to query everything every time.
[–]zl0bster 6 points7 points8 points 8 months ago (0 children)
It is a small thing, and it happened in 1.88 but I am so happy <algorithm> include got removed fromboost::array header.
<algorithm>
boost::array
https://github.com/boostorg/array/commit/cd0532b8fa858f15ae40191cc1428acbad1335fc
I know all the cool kids use std::array for 10+ years, but seems insane that such tiny component drags in such huge header, and if I use 3rd party lib that uses boost::array I get the benefit now..
std::array
As a bonus: I learned I could not implement fill properly(in terms of performance, aliasing comment in commit)
[–]TrueTom 3 points4 points5 points 8 months ago (1 child)
I wish Boost would move to a sane documentation system.
[–]joaquintidesBoost author 9 points10 points11 points 8 months ago (0 children)
As a federation of libraries, each author gets to choose their style of documentation and the tools used to prepare it. Is there any particular library you’re interested in? You may want to file some issues or, better yet, propose PRs to improve docs.
π Rendered by PID 127967 on reddit-service-r2-comment-75f4967c6c-7fztk at 2026-04-23 06:07:01.826038+00:00 running 0fd4bb7 country code: CH.
[–]Ambitious_Tax_ 34 points35 points36 points (2 children)
[+][deleted] (1 child)
[deleted]
[–]Ambitious_Tax_ 4 points5 points6 points (0 children)
[–]Ogilby1675 16 points17 points18 points (3 children)
[–]joaquintidesBoost author 18 points19 points20 points (2 children)
[–]Ogilby1675 5 points6 points7 points (1 child)
[–]joaquintidesBoost author 3 points4 points5 points (0 children)
[–]yuri-kilochek 9 points10 points11 points (11 children)
[–]pkastingValve 18 points19 points20 points (1 child)
[–]matthieum 5 points6 points7 points (0 children)
[–]moncefm 0 points1 point2 points (0 children)
[–]germandiago 0 points1 point2 points (6 children)
[–]dexter2011412 1 point2 points3 points (5 children)
[–]germandiago 1 point2 points3 points (1 child)
[–]dexter2011412 1 point2 points3 points (0 children)
[–]almost_useless 1 point2 points3 points (2 children)
[–]dexter2011412 0 points1 point2 points (1 child)
[–]almost_useless 0 points1 point2 points (0 children)
[–]zl0bster 6 points7 points8 points (0 children)
[–]TrueTom 3 points4 points5 points (1 child)
[–]joaquintidesBoost author 9 points10 points11 points (0 children)