LLVM  14.0.0git
Public Member Functions | List of all members
llvm::pointee_iterator< WrappedIteratorT, T > Struct Template Reference

An iterator type that allows iterating over the pointees via some other iterator. More...

#include "llvm/ADT/iterator.h"

Inheritance diagram for llvm::pointee_iterator< WrappedIteratorT, T >:
Inheritance graph
[legend]
Collaboration diagram for llvm::pointee_iterator< WrappedIteratorT, T >:
Collaboration graph
[legend]

Public Member Functions

 pointee_iterator ()=default
 
template<typename U >
 pointee_iterator (U &&u)
 
Toperator* () const
 
- Public Member Functions inherited from llvm::iterator_adaptor_base< DerivedT, WrappedIteratorT, IteratorCategoryT, T, DifferenceTypeT, PointerT, ReferenceT >
DerivedT & operator+= (difference_type n)
 
DerivedT & operator-= (difference_type n)
 
difference_type operator- (const DerivedT &RHS) const
 
DerivedT & operator++ ()
 
DerivedT & operator-- ()
 
ReferenceT operator* () const
 
- Public Member Functions inherited from llvm::iterator_facade_base< DerivedT, typename std::iterator_traits< WrappedIteratorT >::iterator_category, typename std::iterator_traits< WrappedIteratorT >::value_type, typename std::iterator_traits< WrappedIteratorT >::difference_type, std::conditional_t< std::is_same< typename std::iterator_traits< WrappedIteratorT >::value_type, typename std::iterator_traits< WrappedIteratorT >::value_type >::value, typename std::iterator_traits< WrappedIteratorT >::pointer, typename std::iterator_traits< WrappedIteratorT >::value_type * >, std::conditional_t< std::is_same< typename std::iterator_traits< WrappedIteratorT >::value_type, typename std::iterator_traits< WrappedIteratorT >::value_type >::value, typename std::iterator_traits< WrappedIteratorT >::reference, typename std::iterator_traits< WrappedIteratorT >::value_type & > >
DerivedT operator+ (typename std::iterator_traits< WrappedIteratorT >::difference_type n) const
 
DerivedT operator- (typename std::iterator_traits< WrappedIteratorT >::difference_type n) const
 
DerivedT & operator++ ()
 
DerivedT operator++ (int)
 
DerivedT & operator-- ()
 
DerivedT operator-- (int)
 
bool operator!= (const DerivedT &RHS) const
 
bool operator> (const DerivedT &RHS) const
 
bool operator<= (const DerivedT &RHS) const
 
bool operator>= (const DerivedT &RHS) const
 
PointerProxy operator-> ()
 
PointerProxy operator-> () const
 
ReferenceProxy operator[] (typename std::iterator_traits< WrappedIteratorT >::difference_type n)
 
ReferenceProxy operator[] (typename std::iterator_traits< WrappedIteratorT >::difference_type n) const
 

Additional Inherited Members

- Public Types inherited from llvm::iterator_adaptor_base< DerivedT, WrappedIteratorT, IteratorCategoryT, T, DifferenceTypeT, PointerT, ReferenceT >
using difference_type = DifferenceTypeT
 
- Public Types inherited from llvm::iterator_facade_base< DerivedT, typename std::iterator_traits< WrappedIteratorT >::iterator_category, typename std::iterator_traits< WrappedIteratorT >::value_type, typename std::iterator_traits< WrappedIteratorT >::difference_type, std::conditional_t< std::is_same< typename std::iterator_traits< WrappedIteratorT >::value_type, typename std::iterator_traits< WrappedIteratorT >::value_type >::value, typename std::iterator_traits< WrappedIteratorT >::pointer, typename std::iterator_traits< WrappedIteratorT >::value_type * >, std::conditional_t< std::is_same< typename std::iterator_traits< WrappedIteratorT >::value_type, typename std::iterator_traits< WrappedIteratorT >::value_type >::value, typename std::iterator_traits< WrappedIteratorT >::reference, typename std::iterator_traits< WrappedIteratorT >::value_type & > >
using iterator_category = typename std::iterator_traits< WrappedIteratorT >::iterator_category
 
using value_type = typename std::iterator_traits< WrappedIteratorT >::value_type
 
using difference_type = typename std::iterator_traits< WrappedIteratorT >::difference_type
 
using pointer = std::conditional_t< std::is_same< typename std::iterator_traits< WrappedIteratorT >::value_type, typename std::iterator_traits< WrappedIteratorT >::value_type >::value, typename std::iterator_traits< WrappedIteratorT >::pointer, typename std::iterator_traits< WrappedIteratorT >::value_type * >
 
using reference = std::conditional_t< std::is_same< typename std::iterator_traits< WrappedIteratorT >::value_type, typename std::iterator_traits< WrappedIteratorT >::value_type >::value, typename std::iterator_traits< WrappedIteratorT >::reference, typename std::iterator_traits< WrappedIteratorT >::value_type & >
 
- Protected Types inherited from llvm::iterator_facade_base< DerivedT, typename std::iterator_traits< WrappedIteratorT >::iterator_category, typename std::iterator_traits< WrappedIteratorT >::value_type, typename std::iterator_traits< WrappedIteratorT >::difference_type, std::conditional_t< std::is_same< typename std::iterator_traits< WrappedIteratorT >::value_type, typename std::iterator_traits< WrappedIteratorT >::value_type >::value, typename std::iterator_traits< WrappedIteratorT >::pointer, typename std::iterator_traits< WrappedIteratorT >::value_type * >, std::conditional_t< std::is_same< typename std::iterator_traits< WrappedIteratorT >::value_type, typename std::iterator_traits< WrappedIteratorT >::value_type >::value, typename std::iterator_traits< WrappedIteratorT >::reference, typename std::iterator_traits< WrappedIteratorT >::value_type & > >
enum  
 
- Protected Member Functions inherited from llvm::iterator_adaptor_base< DerivedT, WrappedIteratorT, IteratorCategoryT, T, DifferenceTypeT, PointerT, ReferenceT >
 iterator_adaptor_base ()=default
 
 iterator_adaptor_base (WrappedIteratorT u)
 
const WrappedIteratorTwrapped () const
 
- Protected Attributes inherited from llvm::iterator_adaptor_base< DerivedT, WrappedIteratorT, IteratorCategoryT, T, DifferenceTypeT, PointerT, ReferenceT >
WrappedIteratorT I
 

Detailed Description

template<typename WrappedIteratorT, typename T = std::remove_reference_t<decltype( **std::declval<WrappedIteratorT>())>>
struct llvm::pointee_iterator< WrappedIteratorT, T >

An iterator type that allows iterating over the pointees via some other iterator.

The typical usage of this is to expose a type that iterates over Ts, but which is implemented with some iterator over T*s:

using iterator = pointee_iterator<SmallVectorImpl<T *>::iterator>;

Definition at line 314 of file iterator.h.

Constructor & Destructor Documentation

◆ pointee_iterator() [1/2]

template<typename WrappedIteratorT , typename T = std::remove_reference_t<decltype( **std::declval<WrappedIteratorT>())>>
llvm::pointee_iterator< WrappedIteratorT, T >::pointee_iterator ( )
default

◆ pointee_iterator() [2/2]

template<typename WrappedIteratorT , typename T = std::remove_reference_t<decltype( **std::declval<WrappedIteratorT>())>>
template<typename U >
llvm::pointee_iterator< WrappedIteratorT, T >::pointee_iterator ( U &&  u)
inline

Definition at line 321 of file iterator.h.

Member Function Documentation

◆ operator*()

template<typename WrappedIteratorT , typename T = std::remove_reference_t<decltype( **std::declval<WrappedIteratorT>())>>
T& llvm::pointee_iterator< WrappedIteratorT, T >::operator* ( ) const
inline

The documentation for this struct was generated from the following file: