#pragma once
#include <utility>
#include <pipe/traits.h>

namespace pipe { namespace algorithm {

template <typename Generator, typename Algorithm, typename _ = std::enable_if<pipe::is_generator<Generator>::value>::type>
auto operator|(Generator& gen, Algorithm algorithm)
{
    return algorithm(std::move(gen));
}

}} // namespace pipe::algorithm

#pragma once
#include <utility>
#include <pipe/traits.h>

namespace pipe { namespace algorithm { namespace details {

template <typename Generator, typename Algorithm, typename _ = std::enable_if<pipe::is_generator<Generator>::value>::type>
auto operator|(Generator& gen, Algorithm algorithm)
{
    return algorithm(std::move(gen));
}

}}} // namespace pipe::algorithm::details

Move operator| in details namespace
Move operator| in details namespace
