11inline constexpr bool isspace(
char ch)
noexcept
14 return ch ==
' ' || (
static_cast<unsigned>(ch) -
'\t') < 5;
32template <
typename BaseIterator,
33 bool predicate(
typename std::iterator_traits<BaseIterator>::value_type)
noexcept>
37 using difference_type =
typename std::iterator_traits<BaseIterator>::difference_type;
40 using value_type =
typename std::iterator_traits<BaseIterator>::value_type;
43 using pointer =
typename std::iterator_traits<BaseIterator>::pointer;
46 using reference =
typename std::iterator_traits<BaseIterator>::reference;
53 BaseIterator base_end;
56 constexpr void forward_to_next_value() noexcept
58 for (; base != base_end; ++base)
68 constexpr filter_iterator(BaseIterator it, BaseIterator end) noexcept : base{it}, base_end{end}
70 forward_to_next_value();
85 forward_to_next_value();
96template <
typename BaseIterator>
103template <
typename BaseIterator>
EVMC C++ API - wrappers and bindings for C++.
constexpr bool is_not_space(char ch) noexcept
Checks if a character is not a white space.
constexpr bool isspace(char ch) noexcept
The constexpr variant of std::isspace().
The filter iterator adaptor creates a view of an iterator range in which some elements of the range a...
constexpr void operator++() noexcept
The increment operator.
constexpr bool operator!=(const filter_iterator &o) const noexcept
The inequality operator.
typename std::iterator_traits< BaseIterator >::reference reference
The iterator reference type.
typename std::iterator_traits< BaseIterator >::difference_type difference_type
The iterator difference type.
typename std::iterator_traits< BaseIterator >::value_type value_type
The iterator value type.
typename std::iterator_traits< BaseIterator >::pointer pointer
The iterator pointer type.
constexpr auto operator*() noexcept
The dereference operator.
constexpr filter_iterator(BaseIterator it, BaseIterator end) noexcept
The constructor of the base iterator pair.
std::input_iterator_tag iterator_category
The iterator category.
constexpr bool operator==(const filter_iterator &o) const noexcept
The equality operator.
The input filter iterator which skips whitespace characters from the base input iterator.