Though I dislike the vector<bool> specialization, but frankly, I am yet to need vectors of bools so it never bothered me in practice. I always wondered if anyone actually used it in production code and what were the use cases.
"As an STL container, there are really only two things wrong with vector< bool >. First, it's not an STL container. Second, it doesn't hold bools. Other than that, there's not much to object to." Scott Meyers
It was just a quote that amused me, I have in fact used it as storage for prime numbers when using a sieve of Eratosthenes method of calculating them. The optimisation made my computer able to store considerable more primes than I could have otherwise. The source is here if you're interested https://github.com/davidcorne/Prime_Sieve
Add a comment...