HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
UT_Span.h File Reference
#include "UT_Assert.h"
#include <array>
#include <cstddef>
#include <cstdint>
#include <type_traits>
+ Include dependency graph for UT_Span.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  TCB_SPAN_NAMESPACE_NAME::span< ElementType, Extent >
 
struct  TCB_SPAN_NAMESPACE_NAME::detail::span_storage< E, S >
 
struct  TCB_SPAN_NAMESPACE_NAME::detail::span_storage< E, dynamic_extent >
 
struct  TCB_SPAN_NAMESPACE_NAME::detail::is_span< typename >
 
struct  TCB_SPAN_NAMESPACE_NAME::detail::is_span< span< T, S > >
 
struct  TCB_SPAN_NAMESPACE_NAME::detail::is_std_array< typename >
 
struct  TCB_SPAN_NAMESPACE_NAME::detail::is_std_array< std::array< T, N > >
 
struct  TCB_SPAN_NAMESPACE_NAME::detail::has_size_and_data< typename, typename >
 
struct  TCB_SPAN_NAMESPACE_NAME::detail::has_size_and_data< T, void_t< decltype(detail::size(std::declval< T >())), decltype(detail::data(std::declval< T >()))> >
 
struct  TCB_SPAN_NAMESPACE_NAME::detail::is_container< C, U >
 
struct  TCB_SPAN_NAMESPACE_NAME::detail::is_container_element_type_compatible< typename, typename, typename >
 
struct  TCB_SPAN_NAMESPACE_NAME::detail::is_container_element_type_compatible< T, E, typename std::enable_if< !std::is_same< typename std::remove_cv< decltype(detail::data(std::declval< T >()))>::type, void >::value &&std::is_convertible< remove_pointer_t< decltype(detail::data(std::declval< T >()))>(*)[], E(*)[]>::value >::type >
 
struct  TCB_SPAN_NAMESPACE_NAME::detail::is_complete< typename, typename >
 
struct  TCB_SPAN_NAMESPACE_NAME::detail::is_complete< T, decltype(sizeof(T))>
 
class  TCB_SPAN_NAMESPACE_NAME::span< ElementType, Extent >
 
class  std::tuple_size< TCB_SPAN_NAMESPACE_NAME::span< ElementType, Extent > >
 
class  std::tuple_element< I, TCB_SPAN_NAMESPACE_NAME::span< ElementType, Extent > >
 
struct  UT_DeepEqual< SPANL, SPANR >
 
struct  UT_ShallowEqual< SPANL, SPANR >
 
struct  UT_DeepEqual< UT_Span< ElementType, ExtentL >, UT_Span< ElementType, ExtentR > >
 
struct  UT_ShallowEqual< UT_Span< ElementType, ExtentL >, UT_Span< ElementType, ExtentR > >
 

Namespaces

 TCB_SPAN_NAMESPACE_NAME
 
 TCB_SPAN_NAMESPACE_NAME::detail
 
 std
 

Macros

#define TCB_SPAN_NAMESPACE_NAME   UT::tcb
 
#define TCB_SPAN_NO_CONTRACT_CHECKING
 
#define TCB_SPAN_EXPECT(cond)   UT_ASSERT(cond)
 
#define TCB_SPAN_INLINE_VAR
 
#define TCB_SPAN_CONSTEXPR14
 
#define TCB_SPAN_CONSTEXPR_ASSIGN
 
#define TCB_SPAN_CONSTEXPR11   constexpr
 
#define TCB_SPAN_ARRAY_CONSTEXPR
 
#define TCB_SPAN_NODISCARD
 
#define TCB_SPAN_HPP_INCLUDED
 
#define TCB_SPAN_NO_EXCEPTIONS
 

Typedefs

using TCB_SPAN_NAMESPACE_NAME::byte = unsigned char
 
template<typename... >
using TCB_SPAN_NAMESPACE_NAME::detail::void_t = void
 
template<typename T >
using TCB_SPAN_NAMESPACE_NAME::detail::uncvref_t = typename std::remove_cv< typename std::remove_reference< T >::type >::type
 
template<typename T >
using TCB_SPAN_NAMESPACE_NAME::detail::remove_pointer_t = typename std::remove_pointer< T >::type
 
template<typename ElementType , std::size_t Extent = TCB_SPAN_NAMESPACE_NAME::dynamic_extent>
using UT_Span = TCB_SPAN_NAMESPACE_NAME::span< ElementType, Extent >
 

Functions

template<class C >
constexpr auto TCB_SPAN_NAMESPACE_NAME::detail::size (const C &c) -> decltype(c.size())
 
template<class T , std::size_t N>
constexpr std::size_t TCB_SPAN_NAMESPACE_NAME::detail::size (const T(&)[N]) noexcept
 
template<class C >
constexpr auto TCB_SPAN_NAMESPACE_NAME::detail::data (C &c) -> decltype(c.data())
 
template<class C >
constexpr auto TCB_SPAN_NAMESPACE_NAME::detail::data (const C &c) -> decltype(c.data())
 
template<class T , std::size_t N>
constexpr T * TCB_SPAN_NAMESPACE_NAME::detail::data (T(&array)[N]) noexcept
 
template<class E >
constexpr const E * TCB_SPAN_NAMESPACE_NAME::detail::data (std::initializer_list< E > il) noexcept
 
template<typename ElementType , std::size_t Extent>
constexpr span< ElementType,
Extent > 
TCB_SPAN_NAMESPACE_NAME::make_span (span< ElementType, Extent > s) noexcept
 
template<typename T , std::size_t N>
constexpr span< T, N > TCB_SPAN_NAMESPACE_NAME::make_span (T(&arr)[N]) noexcept
 
template<typename T , std::size_t N>
TCB_SPAN_ARRAY_CONSTEXPR span
< T, N > 
TCB_SPAN_NAMESPACE_NAME::make_span (std::array< T, N > &arr) noexcept
 
template<typename T , std::size_t N>
TCB_SPAN_ARRAY_CONSTEXPR span
< const T, N > 
TCB_SPAN_NAMESPACE_NAME::make_span (const std::array< T, N > &arr) noexcept
 
template<typename Container >
constexpr span< typename
std::remove_reference
< decltype(*detail::data(std::declval
< Container & >)))>::type
TCB_SPAN_NAMESPACE_NAME::make_span (Container &cont)
 
template<typename Container >
constexpr span< const typename
Container::value_type > 
TCB_SPAN_NAMESPACE_NAME::make_span (const Container &cont)
 
template<typename ElementType , std::size_t Extent>
span< const byte,((Extent==dynamic_extent)?dynamic_extent:sizeof(ElementType)*Extent)> TCB_SPAN_NAMESPACE_NAME::as_bytes (span< ElementType, Extent > s) noexcept
 
template<class ElementType , size_t Extent, typename std::enable_if<!std::is_const< ElementType >::value, int >::type = 0>
span< byte,((Extent==dynamic_extent)?dynamic_extent:sizeof(ElementType)*Extent)> TCB_SPAN_NAMESPACE_NAME::as_writable_bytes (span< ElementType, Extent > s) noexcept
 
template<std::size_t N, typename E , std::size_t S>
constexpr auto TCB_SPAN_NAMESPACE_NAME::get (span< E, S > s) -> decltype(s[N])
 
template<typename SPANL , typename SPANR >
constexpr bool UTdeepEqual (const SPANL &left, const SPANR &right)
 
template<typename SPANL , typename SPANR >
constexpr bool UTshallowEqual (const SPANL &left, const SPANR &right)
 

Variables

TCB_SPAN_INLINE_VAR constexpr
std::size_t 
TCB_SPAN_NAMESPACE_NAME::dynamic_extent = SIZE_MAX
 

Macro Definition Documentation

#define TCB_SPAN_ARRAY_CONSTEXPR

Definition at line 157 of file UT_Span.h.

#define TCB_SPAN_CONSTEXPR11   constexpr

Definition at line 137 of file UT_Span.h.

#define TCB_SPAN_CONSTEXPR14

Definition at line 126 of file UT_Span.h.

#define TCB_SPAN_CONSTEXPR_ASSIGN

Definition at line 133 of file UT_Span.h.

#define TCB_SPAN_EXPECT (   cond)    UT_ASSERT(cond)

Definition at line 109 of file UT_Span.h.

#define TCB_SPAN_HPP_INCLUDED

Source from https://github.com/tcbrindle/span

Definition at line 36 of file UT_Span.h.

#define TCB_SPAN_INLINE_VAR

Definition at line 115 of file UT_Span.h.

#define TCB_SPAN_NAMESPACE_NAME   UT::tcb

Definition at line 18 of file UT_Span.h.

#define TCB_SPAN_NO_CONTRACT_CHECKING

Definition at line 76 of file UT_Span.h.

#define TCB_SPAN_NO_EXCEPTIONS

Source from https://github.com/tcbrindle/span

Definition at line 46 of file UT_Span.h.

#define TCB_SPAN_NODISCARD

Definition at line 169 of file UT_Span.h.

Typedef Documentation

template<typename ElementType , std::size_t Extent = TCB_SPAN_NAMESPACE_NAME::dynamic_extent>
using UT_Span = TCB_SPAN_NAMESPACE_NAME::span<ElementType, Extent>

End of source from https://github.com/tcbrindle/span

Definition at line 662 of file UT_Span.h.

Function Documentation

template<typename SPANL , typename SPANR >
constexpr bool UTdeepEqual ( const SPANL &  left,
const SPANR &  right 
)

Definition at line 704 of file UT_Span.h.

template<typename SPANL , typename SPANR >
constexpr bool UTshallowEqual ( const SPANL &  left,
const SPANR &  right 
)

Definition at line 711 of file UT_Span.h.