ID 5782941
Пользователь Кузьмин Захар Данилович
Время 00:19<< 16.11.2021 00:20 (26 д. 22:21) 00:21>>
Обработка 00:20 ... 00:20 (1,96 сек.)
Файл 5782941.cpp (CLang++ 5.0.0 + Address Sanitizer)
Турнир 2 курс. Программирование на C++. Турнир 2, осень 2021
Задача D: FixedAllocator
Набор тестов
Ограничения Время: 2с Память: 128Мб
Состояние  [?]
CE Ошибка компиляции
код | результаты
In file included from main.cpp:28:0:
fixed_allocator.h: In destructor 'FixedAllocator<Tp>::~FixedAllocator()':
fixed_allocator.h:38:16: error: there are no arguments to 'clear' that depend on a template parameter, so a declaration of 'clear' must be available [-fpermissive]
         delete clear();
                ^~~~~
fixed_allocator.h:38:16: note: (if you use '-fpermissive', G++ will accept your code, but allowing the use of an undeclared name is deprecated)
fixed_allocator.h: In instantiation of 'FixedAllocator<Tp>::~FixedAllocator() [with Tp = int]':
main.cpp:44:32:   required from here
fixed_allocator.h:38:21: error: 'clear' was not declared in this scope
         delete clear();
                ~~~~~^~
fixed_allocator.h:38:21: note: suggested alternative: 'char'
         delete clear();
                ~~~~~^~
                char
fixed_allocator.h: In instantiation of 'FixedAllocator<Tp>::~FixedAllocator() [with Tp = std::__cxx11::basic_string<char>]':
main.cpp:55:41:   required from here
fixed_allocator.h:38:21: error: 'clear' was not declared in this scope
fixed_allocator.h:38:21: note: suggested alternative: 'char'
         delete clear();
                ~~~~~^~
                char
fixed_allocator.h: In instantiation of 'FixedAllocator<Tp>::~FixedAllocator() [with Tp = char]':
main.cpp:116:35:   required from here
fixed_allocator.h:38:21: error: 'clear' was not declared in this scope
fixed_allocator.h:38:21: note: suggested alternative: 'char'
         delete clear();
                ~~~~~^~
                char
0.054s 0.011s 9