tetl
0.1.0
Embedded Template Library
Loading...
Searching...
No Matches
isspace.hpp
Go to the documentation of this file.
1
// SPDX-License-Identifier: BSL-1.0
2
3
#ifndef TETL_CCTYPE_ISSPACE_HPP
4
#define TETL_CCTYPE_ISSPACE_HPP
5
6
namespace
etl
{
7
19
[[nodiscard]]
constexpr
auto
isspace
(
int
ch)
noexcept
->
int
20
{
21
auto
const
sp = ch ==
' '
;
22
auto
const
form = ch ==
'\f'
;
23
auto
const
line = ch ==
'\n'
;
24
auto
const
carriage = ch ==
'\r'
;
25
auto
const
hTab = ch ==
'\t'
;
26
auto
const
vTab = ch ==
'\v'
;
27
return
static_cast<
int
>
(sp || form || line || carriage || hTab || vTab);
28
}
29
}
// namespace etl
30
31
#endif
// TETL_CCTYPE_ISSPACE_HPP
etl::isspace
constexpr auto isspace(int ch) noexcept -> int
Checks if the given character is whitespace character as classified by the default C locale.
Definition
isspace.hpp:19
etl
Definition
adjacent_find.hpp:8
include
etl
_cctype
isspace.hpp
Generated on Sat Mar 8 2025 16:19:59 for tetl by
1.14.0