Template Class SmallVectorTemplateCommon¶
Defined in File SmallVector.hpp
Inheritance Relationships¶
Base Type¶
public ams::SmallVectorBase< SmallVectorSizeType< T > >(Template Class SmallVectorBase)
Derived Types¶
public ams::SmallVectorTemplateBase< IntDimType >(Template Class SmallVectorTemplateBase)public ams::SmallVectorTemplateBase< T, bool >(Template Class SmallVectorTemplateBase)public ams::SmallVectorTemplateBase< T, true >(Template Class SmallVectorTemplateBase< T, true >)
Class Documentation¶
-
template<typename T, typename = void>
class SmallVectorTemplateCommon : public ams::SmallVectorBase<SmallVectorSizeType<T>>¶ This is the part of SmallVectorTemplateBase which does not depend on whether the type T is a POD. The extra dummy template argument is used by ArrayRef to avoid unnecessarily requiring T to be complete.
Subclassed by ams::SmallVectorTemplateBase< IntDimType >, ams::SmallVectorTemplateBase< T, bool >, ams::SmallVectorTemplateBase< T, true >
Public Types
-
using size_type = size_t¶
-
using difference_type = ptrdiff_t¶
-
using const_reverse_iterator = std::reverse_iterator<const_iterator>¶
Public Functions
-
inline const_iterator begin() const¶
-
inline const_iterator end() const¶
-
inline reverse_iterator rbegin()¶
-
inline const_reverse_iterator rbegin() const¶
-
inline reverse_iterator rend()¶
-
inline const_reverse_iterator rend() const¶
-
inline size_t capacity_in_bytes() const¶
-
inline const_pointer data() const¶
Return a pointer to the vector’s buffer, even if empty().
-
inline const_reference operator[](size_type idx) const¶
-
inline const_reference front() const¶
-
inline const_reference back() const¶
Protected Functions
-
inline void *getFirstEl() const¶
Find the address of the first element. For this pointer math to be valid with small-size of 0 for T with lots of alignment, it’s important that SmallVectorStorage is properly-aligned even for small-size of 0.
-
inline SmallVectorTemplateCommon(size_t Size)¶
-
inline void grow_pod(size_t MinSize, size_t TSize)¶
-
inline bool isSmall() const¶
Return true if this is a smallvector which has not had dynamic memory allocated for it.
-
inline void resetToSmall()¶
Put this vector in a state of being small.
-
inline bool isReferenceToRange(const void *V, const void *First, const void *Last) const¶
Return true if V is an internal reference to the given range.
-
inline bool isReferenceToStorage(const void *V) const¶
Return true if V is an internal reference to this vector.
-
inline bool isRangeInStorage(const void *First, const void *Last) const¶
Return true if First and Last form a valid (possibly empty) range in this vector’s storage.
-
inline bool isSafeToReferenceAfterResize(const void *Elt, size_t NewSize)¶
Return true unless Elt will be invalidated by resizing the vector to NewSize.
-
inline void assertSafeToReferenceAfterResize(const void *Elt, size_t NewSize)¶
Check whether Elt will be invalidated by resizing the vector to NewSize.
-
inline void assertSafeToAdd(const void *Elt, size_t N = 1)¶
Check whether Elt will be invalidated by increasing the size of the vector by N.
-
inline void assertSafeToReferenceAfterClear(const T *From, const T *To)¶
Check whether any part of the range will be invalidated by clearing.
-
template<class ItTy, std::enable_if_t<!std::is_same<std::remove_const_t<ItTy>, T*>::value, bool> = false>
inline void assertSafeToReferenceAfterClear(ItTy, ItTy)¶
-
using size_type = size_t¶