diff options
| author | Chris Lattner <sabre@nondot.org> | 2009-05-04 02:19:15 +0000 |
|---|---|---|
| committer | Chris Lattner <sabre@nondot.org> | 2009-05-04 02:19:15 +0000 |
| commit | 0fc8a35fb86328a46d6a621abd7b608b1255b9b8 (patch) | |
| tree | 45fd7182bc5f2a26915215d66cf691063e26dff8 /llvm/include | |
| parent | 4ddeb20743e3063ae8ab88895cd294a408f4ef3e (diff) | |
| download | bcm5719-llvm-0fc8a35fb86328a46d6a621abd7b608b1255b9b8.tar.gz bcm5719-llvm-0fc8a35fb86328a46d6a621abd7b608b1255b9b8.zip | |
add a range insertion method to SmallSet.
llvm-svn: 70817
Diffstat (limited to 'llvm/include')
| -rw-r--r-- | llvm/include/llvm/ADT/SmallSet.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/llvm/include/llvm/ADT/SmallSet.h b/llvm/include/llvm/ADT/SmallSet.h index 75e8c64885a..caaa96c045f 100644 --- a/llvm/include/llvm/ADT/SmallSet.h +++ b/llvm/include/llvm/ADT/SmallSet.h @@ -76,6 +76,12 @@ public: return true; } + template <typename IterT> + void insert(IterT I, IterT E) { + for (; I != E; ++I) + insert(*I); + } + bool erase(const T &V) { if (!isSmall()) return Set.erase(V); |

