userver: userver/utils/span.hpp File Reference
Loading...
Searching...
No Matches
span.hpp File Reference

Detailed Description

A polyfill for std::span from C++20.

Definition in file span.hpp.

Go to the source code of this file.

#include <cstddef>
#include <iterator>
#include <type_traits>
#include <userver/utils/assert.hpp>
+ This graph shows which files directly or indirectly include this file:

Classes

class  utils::span< T >
 A polyfill for std::span from C++20. More...
 

Namespaces

namespace  utils
 Utilities.
 

Functions

template<typename Container >
 utils::span (Container &&cont) -> span< std::remove_reference_t< decltype(*std::begin(cont))> >
 
template<typename T >
span< const std::byte > utils::as_bytes (span< T > s) noexcept
 A polyfill for std::as_bytes from C++20.
 
template<typename T >
span< std::byte > utils::as_writable_bytes (span< T > s) noexcept
 A polyfill for std::as_writable_bytes from C++20.