5#ifndef INCLUDE_GUARD_ARENE_BASE_ARENE_BASE_STRINGS_ALGORITHM_TRIM_HPP_
6#define INCLUDE_GUARD_ARENE_BASE_ARENE_BASE_STRINGS_ALGORITHM_TRIM_HPP_
13#include "arene/base/stdlib_choice/cstddef.hpp"
37 return str.substr(start);
45template <std::
size_t MaxLength>
61 return str.substr(0U, end + 1U);
70template <std::
size_t MaxLength>
86template <std::
size_t MaxLength>
A string type with a fixed maximum capacity, where the data is stored internally without allocations.
Definition inline_string.hpp:162
Backport of the C++17 std::string_view class.
Definition string_view.hpp:54
static constexpr std::size_t npos
Special marker value for end of string.
Definition string_view.hpp:69
Definition accumulate.hpp:37
constexpr auto trim(string_view const str) -> string_view
Create a copy of the string view with leading and trailing whitespace removed.
Definition trim.hpp:79
constexpr auto whitespace_chars() -> string_view
Characters defined as whitespace to be trimmed.
Definition trim.hpp:26
constexpr auto rtrim(string_view const str) -> string_view
Create a copy of the string view with trailing whitespace removed.
Definition trim.hpp:55
constexpr auto ltrim(string_view const str) -> string_view
Create a copy of the string view with leading whitespace removed.
Definition trim.hpp:32
Definition accumulate.hpp:36
::size_t size_t
A type suitable for holding the size of an object.
Definition cstddef.hpp:29