Borderou de evaluare (job #3210114)

Utilizator Theo20067Cismaru Theodor-Alexe Theo20067 Data 5 martie 2024 01:24:53
Problema Praslea Status done
Runda Arhiva de probleme Compilator cpp-64 | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: In file included from /usr/include/c++/12.2.1/set:60, from main.cpp:4: /usr/include/c++/12.2.1/bits/stl_tree.h: In instantiation of 'static const _Key& std::_Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::_S_key(_Const_Link_type) [with _Key = elem1; _Val = elem1; _KeyOfValue = std::_Identity<elem1>; _Compare = cmp; _Alloc = std::allocator<elem1>; _Const_Link_type = const std::_Rb_tree_node<elem1>*]': /usr/include/c++/12.2.1/bits/stl_tree.h:2148:44: required from 'std::pair<std::_Rb_tree_node_base*, std::_Rb_tree_node_base*> std::_Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::_M_get_insert_equal_pos(const key_type&) [with _Key = elem1; _Val = elem1; _KeyOfValue = std::_Identity<elem1>; _Compare = cmp; _Alloc = std::allocator<elem1>; key_type = elem1]' /usr/include/c++/12.2.1/bits/stl_tree.h:2197:4: required from 'std::_Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::iterator std::_Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::_M_insert_equal(_Arg&&) [with _Arg = elem1; _Key = elem1; _Val = elem1; _KeyOfValue = std::_Identity<elem1>; _Compare = cmp; _Alloc = std::allocator<elem1>; iterator = std::_Rb_tree<elem1, elem1, std::_Identity<elem1>, cmp, std::allocator<elem1> >::iterator]' /usr/include/c++/12.2.1/bits/stl_multiset.h:509:36: required from 'std::multiset<_Key, _Compare, _Alloc>::iterator std::multiset<_Key, _Compare, _Alloc>::insert(value_type&&) [with _Key = elem1; _Compare = cmp; _Alloc = std::allocator<elem1>; iterator = std::_Rb_tree<elem1, elem1, std::_Identity<elem1>, cmp, std::allocator<elem1> >::const_iterator; value_type = elem1]' main.cpp:47:21: required from here /usr/include/c++/12.2.1/bits/stl_tree.h:770:15: error: static assertion failed: comparison object must be invocable as const 770 | is_invocable_v<const _Compare&, const _Key&, const _Key&>, | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /usr/include/c++/12.2.1/bits/stl_tree.h:770:15: note: 'std::is_invocable_v<const cmp&, const elem1&, const elem1&>' evaluates to false Non zero exit status: 1

Ceva nu functioneaza?