Opened 3 years ago

Closed 3 years ago

#732 closed ожидается проверка (задача сдана)

WW #14 (Ushakov)

Reported by: ushakov.vladislav Owned by: Святослав Власов
Component: WW_linq Version: 1.0
Keywords: Cc:

Description


Change History (3)

comment:1 Changed 3 years ago by Святослав Власов

Type: ожидается проверкаожидаются исправления

Не собралось

src/linq_tests.cpp: In function ‘void test_copy_to()’:
src/linq_tests.cpp:146:45: error: cannot bind non-const lvalue reference of type ‘std::back_insert_iterator<std::vector<std::__cxx11::basic_string<char>, std::allocator<std::__cxx11::basic_string<char> > > >&’ to an rvalue of type ‘std::back_insert_iterator<std::vector<std::__cxx11::basic_string<char>, std::allocator<std::__cxx11::basic_string<char> > > >’
  146 |     to_stream(xs).copy_to(std::back_inserter(xs_copy));
      |                           ~~~~~~~~~~~~~~~~~~^~~~~~~~~
In file included from src/linq_tests.cpp:1:
../../../homeworks/ushakov.vladislav/lab_14/include/linq.hpp:88:23: note:   initializing argument 1 of ‘Iter& linq::impl::enumerator<T>::copy_to(Iter&) && [with Iter = std::back_insert_iterator<std::vector<std::__cxx11::basic_string<char>, std::allocator<std::__cxx11::basic_string<char> > > >; T = std::__cxx11::basic_string<char>]’
   88 |   Iter &copy_to(Iter &iter) && {
      |                 ~~~~~~^~~~
src/linq_tests.cpp:156:32: error: cannot bind non-const lvalue reference of type ‘std::ostream_iterator<int>&’ to an rvalue of type ‘std::ostream_iterator<int>’
  156 |     to_stream(xs).copy_to(std::ostream_iterator<int>{std::cout});
      |                                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from src/linq_tests.cpp:1:
../../../homeworks/ushakov.vladislav/lab_14/include/linq.hpp:88:23: note:   initializing argument 1 of ‘Iter& linq::impl::enumerator<T>::copy_to(Iter&) && [with Iter = std::ostream_iterator<int>; T = int]’
   88 |   Iter &copy_to(Iter &iter) && {
      |                 ~~~~~~^~~~
src/linq_tests.cpp:163:45: error: cannot bind non-const lvalue reference of type ‘std::back_insert_iterator<std::vector<std::__cxx11::basic_string<char>, std::allocator<std::__cxx11::basic_string<char> > > >&’ to an rvalue of type ‘std::back_insert_iterator<std::vector<std::__cxx11::basic_string<char>, std::allocator<std::__cxx11::basic_string<char> > > >’
  163 |     to_stream(xs).copy_to(std::back_inserter(xs_copy));
      |                           ~~~~~~~~~~~~~~~~~~^~~~~~~~~
In file included from src/linq_tests.cpp:1:
../../../homeworks/ushakov.vladislav/lab_14/include/linq.hpp:88:23: note:   initializing argument 1 of ‘Iter& linq::impl::enumerator<T>::copy_to(Iter&) && [with Iter = std::back_insert_iterator<std::vector<std::__cxx11::basic_string<char>, std::allocator<std::__cxx11::basic_string<char> > > >; T = std::__cxx11::basic_string<char>]’
   88 |   Iter &copy_to(Iter &iter) && {
      |                 ~~~~~~^~~~
Compilation failed. Abort testing.

comment:2 Changed 3 years ago by ushakov.vladislav

Type: ожидаются исправленияожидается проверка

Уууупс... Почему-то сильно поменял сигнатуру copy_to :/

comment:3 Changed 3 years ago by Святослав Власов

Resolution: задача сдана
Status: assignedclosed

Всё клёво, 10/10

Note: See TracTickets for help on using tickets.