14#include <rpp/operators/lift.hpp>
15#include <rpp/operators/take.hpp>
16#include <rpp/operators/details/subscriber_with_state.hpp>
17#include <rpp/operators/fwd/first.hpp>
18#include <rpp/subscribers/constraints.hpp>
19#include <rpp/utils/exceptions.hpp>
20#include <rpp/utils/functors.hpp>
22IMPLEMENTATION_FILE(first_tag);
38 subscriber.on_error(std::make_exception_ptr(utils::not_enough_emissions{
"first() operator expects at least one emission from observable before completion"}));
42template<constra
int::decayed_type Type>
46 template<constra
int::subscriber_of_type<Type> TSub>
47 auto operator()(TSub&& subscriber)
const
49 auto subscription = subscriber.get_subscription();
52 return create_subscriber_with_dynamic_state<Type>(std::move(subscription),
54 utils::forwarding_on_error{},
56 std::forward<TSub>(subscriber),
Definition: constraints.hpp:19