Opened 4 years ago

Closed 4 years ago

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

WW #10

Reported by: Alexander Morozov Owned by: Sokolov Viacheslav
Component: WW figures Version: 1.0
Keywords: Cc:

Description


Change History (1)

comment:1 Changed 4 years ago by Sokolov Viacheslav

Resolution: задача сдана
Status: assignedclosed
╰─>$ make
mkdir -p obj
g++ -O2 -Wall -Werror -std=c++11 -Iinclude -c -MMD -o obj/Scheme.o src/Scheme.cpp
In file included from /usr/include/c++/9/cassert:44,
                 from src/Scheme.cpp:2:
src/Scheme.cpp: In member function ‘void Scheme::push_back_figure(Figure*)’:
src/Scheme.cpp:24:10: error: ‘figure’ was not declared in this scope; did you mean ‘figures’?
   24 |   assert(figure); // I think nullptr is not allowed here
      |          ^~~~~~
Makefile:17: recipe for target 'obj/Scheme.o' failed
make: *** [obj/Scheme.o] Error 1

Scheme::move не реализован

удобно в codestyle разделять имена членов класса и локальных переменных с помощью разного именования (например, с помощью _), чтобы потом не выделять с помощью this-> то, что онтносится к экземпляру класса

стоило бы добавить assert(factor >= 0);

Note: See TracTickets for help on using tickets.