diff options
author | Douglas Gregor <dgregor@apple.com> | 2012-04-13 16:31:46 +0000 |
---|---|---|
committer | Douglas Gregor <dgregor@apple.com> | 2012-04-13 16:31:46 +0000 |
commit | 87e154c09bbb060a0620bc988d7723bee64fb79c (patch) | |
tree | 8c78ea5379aebabc7c8f2ef38827302614a94601 /include/clang/Index/STLExtras.h | |
parent | b20c46ea980b5aed7b480761ea1daf2f26c23b2d (diff) |
Remove the unused, unmaintained, incomplete 'Index' library.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@154672 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/clang/Index/STLExtras.h')
-rw-r--r-- | include/clang/Index/STLExtras.h | 63 |
1 files changed, 0 insertions, 63 deletions
diff --git a/include/clang/Index/STLExtras.h b/include/clang/Index/STLExtras.h deleted file mode 100644 index a3693c6c79..0000000000 --- a/include/clang/Index/STLExtras.h +++ /dev/null @@ -1,63 +0,0 @@ -//===--- STLExtras.h - Helper STL related templates -------------*- C++ -*-===// -// -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// -// -// Helper templates for using with the STL. -// -//===----------------------------------------------------------------------===// - -#ifndef LLVM_CLANG_INDEX_STLEXTRAS_H -#define LLVM_CLANG_INDEX_STLEXTRAS_H - -namespace clang { - -namespace idx { - -/// \brief Wraps an iterator whose value_type is a pair, and provides -/// pair's second object as the value. -template <typename iter_type> -class pair_value_iterator { - iter_type I; - -public: - typedef typename iter_type::value_type::second_type value_type; - typedef value_type& reference; - typedef value_type* pointer; - typedef typename iter_type::iterator_category iterator_category; - typedef typename iter_type::difference_type difference_type; - - pair_value_iterator() { } - pair_value_iterator(iter_type i) : I(i) { } - - reference operator*() const { return I->second; } - pointer operator->() const { return &I->second; } - - pair_value_iterator& operator++() { - ++I; - return *this; - } - - pair_value_iterator operator++(int) { - pair_value_iterator tmp(*this); - ++(*this); - return tmp; - } - - friend bool operator==(pair_value_iterator L, pair_value_iterator R) { - return L.I == R.I; - } - friend bool operator!=(pair_value_iterator L, pair_value_iterator R) { - return L.I != R.I; - } -}; - -} // end idx namespace - -} // end clang namespace - -#endif |