Wasmtime: C++
All Classes Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
Public Types | Public Member Functions | List of all members
wasmtime::Span< T, Extent > Class Template Reference

Span class used when c++20 is not available. More...

Public Types

using iterator = T *
 Type used to iterate over this span (a raw pointer)
 

Public Member Functions

 Span (T *t, std::size_t n)
 Constructor of Span class.
 
template<typename C , std::enable_if_t< !IsSpan< C >::value && std::is_pointer_v< decltype, T(*) , &&std::is_convertible_v< decltype(std::declval< C >().size()), std::size_t > , int >
 Span (C &range)
 Constructor of Span class for containers.
 
T & operator[] (ptrdiff_t idx) const
 Returns item by index.
 
T * data () const
 Returns pointer to data.
 
std::size_t size () const
 Returns number of data that referred by Span class.
 
iterator begin () const
 Returns begin iterator.
 
iterator end () const
 Returns end iterator.
 
std::size_t size_bytes () const
 Returns size in bytes.
 

Detailed Description

template<typename T, std::size_t Extent>
class wasmtime::Span< T, Extent >

Span class used when c++20 is not available.

Template Parameters
TType of data
ExtentStatic size of data referred by Span class

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