26
Ranges library
[ranges]
26.7
Range adaptors
[range.adaptors]
26.7.11
Take while view
[range.take.while]
26.7.11.3
Class template
take_
while_
view::
sentinel
[range.take.while.sentinel]
namespace
std
::
ranges
{
template
<
view
V,
class
Pred
>
requires
input_
range
<
V
>
&
&
is_object_v
<
Pred
>
&
&
indirect_
unary_
predicate
<
const
Pred, iterator_t
<
V
>
>
template
<
bool
Const
>
class
take_while_view
<
V, Pred
>
::
sentinel
{
using
Base
=
maybe-const
<
Const, V
>
;
//
exposition only
sentinel_t
<
Base
>
end_
=
sentinel_t
<
Base
>
(
)
;
//
exposition only
const
Pred
*
pred_
=
nullptr
;
//
exposition only
public
:
sentinel
(
)
=
default
;
constexpr
explicit
sentinel
(
sentinel_t
<
Base
>
end,
const
Pred
*
pred
)
;
constexpr
sentinel
(
sentinel
<
!
Const
>
s
)
requires
Const
&
&
convertible_
to
<
sentinel_t
<
V
>
, sentinel_t
<
Base
>
>
;
constexpr
sentinel_t
<
Base
>
base
(
)
const
{
return
end_
;
}
friend
constexpr
bool
operator
=
=
(
const
iterator_t
<
Base
>
&
x,
const
sentinel
&
y
)
;
template
<
bool
OtherConst
=
!
Const
>
requires
sentinel_
for
<
sentinel_t
<
Base
>
, iterator_t
<
maybe-const
<
OtherConst, V
>
>
>
friend
constexpr
bool
operator
=
=
(
const
iterator_t
<
maybe-const
<
OtherConst, V
>
>
&
x,
const
sentinel
&
y
)
;
}
;
}
🔗
constexpr
explicit
sentinel
(
sentinel_t
<
Base
>
end,
const
Pred
*
pred
)
;
1
#
Effects
: Initializes
end_
with
end
and
pred_
with
pred