33 #ifndef REMORA_VECTOR_PROXY_HPP 34 #define REMORA_VECTOR_PROXY_HPP 36 #include "detail/expression_optimizers.hpp" 48 template<
class V,
class Device>
49 temporary_proxy<typename detail::vector_range_optimizer<V>::type>
50 subrange(vector_expression<V, Device>& expression, std::size_t start, std::size_t stop){
51 return detail::vector_range_optimizer<V>::create(expression(), start, stop);
54 template<
class V,
class Device>
55 typename detail::vector_range_optimizer<typename const_expression<V>::type>::type
56 subrange(vector_expression<V, Device>
const& expression, std::size_t start, std::size_t stop){
57 return detail::vector_range_optimizer<typename const_expression<V>::type>::create(expression(), start, stop);
61 temporary_proxy<typename detail::vector_range_optimizer<V>::type>
62 subrange(temporary_proxy<V> expression, std::size_t start, std::size_t stop){
63 return subrange(static_cast<V&>(expression), start, stop);
72 temporary_proxy<dense_vector_adaptor<T> > adapt_vector(std::size_t size, T * expression){
73 return dense_vector_adaptor<T>(expression,size);
77 template <
class T, std::
size_t N>
78 temporary_proxy<dense_vector_adaptor<T> > adapt_vector(T (&array)[N]){
79 return dense_vector_adaptor<T>(array,N);