Quick Q: Simultaneously iterating over and modifying an unordered_set? -- StackOverflow
Consider the following code:
unordered_set<T> S = ...; for (const auto& x : S) if (...) S.insert(...);This is broken correct? If we insert something into
Sthen the iterators may be invalidated (due to a rehash), which will break the range-for because under the hood it is usingS.begin...S.end.
Is there some pattern to deal with this?

This week, Faisal Vali shared an initial "alpha" implementation of generic lambdas in Clang. Faisal is the lead author of the proposal (

A C++11 Name-Lookup Problem: a Long-Term Solution and a Temporary Work-Around