[llvm-commits] [llvm] r152143 - in /llvm/trunk: include/llvm/ADT/SmallPtrSet.h lib/Support/SmallPtrSet.cpp unittests/ADT/SmallPtrSetTest.cpp

Duncan Sands baldrick at free.fr
Wed Mar 7 00:32:41 PST 2012


Hi Benjamin,

> SmallPtrSet: Provide a more efficient implementation of swap than the default triple-copy std::swap.
>
> This currently assumes that both sets have the same SmallSize to keep the implementation simple,
> a limitation that can be lifted if someone cares.

how about adding an assertion that checks that they have the same size.

Ciao, Duncan.



More information about the llvm-commits mailing list