prepare (1/3):
finished
make (2/3):
g++ -std=c++11 -O3 -o main main.cpp
In file included from B_order.h:5:0,
from main.cpp:1:
median.h:11:47: error: declaration of 'std::priority_queue<int, std::vector<int>, std::greater<int> > median::less' [-fpermissive]
priority_queue<int,vector<int>,greater<int>> less;
^~~~
In file included from /usr/include/c++/7/string:48:0,
from /usr/include/c++/7/bits/locale_classes.h:40,
from /usr/include/c++/7/bits/ios_base.h:41,
from /usr/include/c++/7/ios:42,
from /usr/include/c++/7/ostream:38,
from /usr/include/c++/7/iostream:39,
from client.h:3,
from B_order.h:4,
from main.cpp:1:
/usr/include/c++/7/bits/stl_function.h:381:12: error: changes meaning of 'less' from 'struct std::less<int>' [-fpermissive]
struct less : public binary_function<_Tp, _Tp, bool>
^~~~
In file included from main.cpp:1:0:
B_order.h:21:10: error: declaration of 'client* B_order::order::client' [-fpermissive]
client *client;
^~~~~~
In file included from B_order.h:4:0,
from main.cpp:1:
client.h:7:7: error: changes meaning of 'client' from 'class client' [-fpermissive]
class client{
^~~~~~
main.cpp: In function 'int main(int, char**)':
main.cpp:56:49: error: no matching function for call to 'std::vector<B_order::order*>::push_back(std::remove_reference<char*&>::type)'
timeTravelers.push_back(move(optarg));
^
In file included from /usr/include/c++/7/vector:64:0,
from /usr/include/c++/7/queue:61,
from median.h:5,
from B_order.h:5,
from main.cpp:1:
/usr/include/c++/7/bits/stl_vector.h:939:7: note: candidate: void std::vector<_Tp, _Alloc>::push_back(const value_type&) [with _Tp = B_order::order*; _Alloc = std::allocator<B_order::order*>; std::vector<_Tp, _Alloc>::value_type = B_order::order*]
push_back(const value_type& __x)
^~~~~~~~~
/usr/include/c++/7/bits/stl_vector.h:939:7: note: no known conversion for argument 1 from 'std::remove_reference<char*&>::type {aka char*}' to 'B_order::order* const&'
/usr/include/c++/7/bits/stl_vector.h:953:7: note: candidate: void std::vector<_Tp, _Alloc>::push_back(std::vector<_Tp, _Alloc>::value_type&&) [with _Tp = B_order::order*; _Alloc = std::allocator<B_order::order*>; std::vector<_Tp, _Alloc>::value_type = B_order::order*]
push_back(value_type&& __x)
^~~~~~~~~
/usr/include/c++/7/bits/stl_vector.h:953:7: note: no known conversion for argument 1 from 'std::remove_reference<char*&>::type {aka char*}' to 'B_order::order*&&'
main.cpp:84:26: error: 'class B_order' has no member named 'isSell'; did you mean 'Sell'?
if(trade->ORDER->isSell){ Sell.erase(trade->ORDER);}
^~~~~~
Sell
main.cpp:84:35: error: 'Sell' was not declared in this scope
if(trade->ORDER->isSell){ Sell.erase(trade->ORDER);}
^~~~
main.cpp:84:35: note: suggested alternative: 'ftell'
if(trade->ORDER->isSell){ Sell.erase(trade->ORDER);}
^~~~
ftell
main.cpp:85:15: error: 'Buy' was not declared in this scope
else{ Buy.erase(trade->ORDER);}
^~~
main.cpp:140:22: error: 'a' was not declared in this scope
ord2->ORDER=a->ORDER;
^
main.cpp:155:24: error: 'timestamp' was not declared in this scope
ord->printMedian(timestamp);
^~~~~~~~~
main.cpp:155:24: note: suggested alternative: 'mkstemp'
ord->printMedian(timestamp);
^~~~~~~~~
mkstemp
main.cpp:160:26: error: 'timestamp' was not declared in this scope
ord->printMidpoint(timestamp);
^~~~~~~~~
main.cpp:160:26: note: suggested alternative: 'mkstemp'
ord->printMidpoint(timestamp);
^~~~~~~~~
mkstemp
main.cpp:170:15: error: invalid use of non-static member function 'void client::print_transfer() const'
client->print_transfer;
~~~~~~~~^~~~~~~~~~~~~~
In file included from B_order.h:4:0,
from main.cpp:1:
client.h:44:6: note: declared here
void client::print_transfer() const{
^~~~~~
main.cpp:173:37: error: no matching function for call to 'std::unordered_map<std::__cxx11::basic_string<char>, B_order*>::find(B_order::order*&)'
auto iter3= ordersMap.find(name);
^
In file included from /usr/include/c++/7/unordered_map:48:0,
from main.cpp:8:
/usr/include/c++/7/bits/unordered_map.h:922:7: note: candidate: std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::iterator std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::find(const key_type&) [with _Key = std::__cxx11::basic_string<char>; _Tp = B_order*; _Hash = std::hash<std::__cxx11::basic_string<char> >; _Pred = std::equal_to<std::__cxx11::basic_string<char> >; _Alloc = std::allocator<std::pair<const std::__cxx11::basic_string<char>, B_order*> >; std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::iterator = std::__detail::_Node_iterator<std::pair<const std::__cxx11::basic_string<char>, B_order*>, false, true>; std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::key_type = std::__cxx11::basic_string<char>]
find(const key_type& __x)
^~~~
/usr/include/c++/7/bits/unordered_map.h:922:7: note: no known conversion for argument 1 from 'B_order::order*' to 'const key_type& {aka const std::__cxx11::basic_string<char>&}'
/usr/include/c++/7/bits/unordered_map.h:926:7: note: candidate: std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::const_iterator std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::find(const key_type&) const [with _Key = std::__cxx11::basic_string<char>; _Tp = B_order*; _Hash = std::hash<std::__cxx11::basic_string<char> >; _Pred = std::equal_to<std::__cxx11::basic_string<char> >; _Alloc = std::allocator<std::pair<const std::__cxx11::basic_string<char>, B_order*> >; std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::const_iterator = std::__detail::_Node_const_iterator<std::pair<const std::__cxx11::basic_string<char>, B_order*>, false, true>; std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::key_type = std::__cxx11::basic_string<char>]
find(const key_type& __x) const
^~~~
/usr/include/c++/7/bits/unordered_map.h:926:7: note: no known conversion for argument 1 from 'B_order::order*' to 'const key_type& {aka const std::__cxx11::basic_string<char>&}'
main.cpp:175:40: error: no matching function for call to 'B_order::B_order(B_order::order*&)'
auto b_order= new B_order(name);
^
In file included from main.cpp:1:0:
B_order.h:67:1: note: candidate: B_order::B_order(const string&)
B_order::B_order(const string &name){
^~~~~~~
B_order.h:67:1: note: no known conversion for argument 1 from 'B_order::order*' to 'const string& {aka const std::__cxx11::basic_string<char>&}'
B_order.h:12:7: note: candidate: B_order::B_order(const B_order&)
class B_order{
^~~~~~~
B_order.h:12:7: note: no known conversion for argument 1 from 'B_order::order*' to 'const B_order&'
B_order.h:12:7: note: candidate: B_order::B_order(B_order&&)
B_order.h:12:7: note: no known conversion for argument 1 from 'B_order::order*' to 'B_order&&'
main.cpp:177:47: error: no matching function for call to 'std::unordered_map<std::__cxx11::basic_string<char>, B_order*>::insert(<brace-enclosed initializer list>)'
iter3=ordersMap.insert({name,b_order}).first;
^
In file included from /usr/include/c++/7/unordered_map:48:0,
from main.cpp:8:
/usr/include/c++/7/bits/unordered_map.h:578:7: note: candidate: std::pair<typename std::_Hashtable<_Key, std::pair<const _Key, _Tp>, _Alloc, std::__detail::_Select1st, _Pred, _Hash, std::__detail::_Mod_range_hashing, std::__detail::_Default_ranged_hash, std::__detail::_Prime_rehash_policy, std::__detail::_Hashtable_traits<std::__not_<std::__and_<std::__is_fast_hash<_Hash>, std::__detail::__is_noexcept_hash<_Key, _Hash> > >::value, false, true> >::iterator, bool> std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::insert(const value_type&) [with _Key = std::__cxx11::basic_string<char>; _Tp = B_order*; _Hash = std::hash<std::__cxx11::basic_string<char> >; _Pred = std::equal_to<std::__cxx11::basic_string<char> >; _Alloc = std::allocator<std::pair<const std::__cxx11::basic_string<char>, B_order*> >; typename std::_Hashtable<_Key, std::pair<const _Key, _Tp>, _Alloc, std::__detail::_Select1st, _Pred, _Hash, std::__detail::_Mod_range_hashing, std::__detail::_Default_ranged_hash, std::__detail::_Prime_rehash_policy, std::__detail::_Hashtable_traits<std::__not_<std::__and_<std::__is_fast_hash<_Hash>, std::__detail::__is_noexcept_hash<_Key, _Hash> > >::value, false, true> >::iterator = std::__detail::_Node_iterator<std::pair<const std::__cxx11::basic_string<char>, B_order*>, false, true>; std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::value_type = std::pair<const std::__cxx11::basic_string<char>, B_order*>]
insert(const value_type& __x)
^~~~~~
/usr/include/c++/7/bits/unordered_map.h:578:7: note: no known conversion for argument 1 from '<brace-enclosed initializer list>' to 'const value_type& {aka const std::pair<const std::__cxx11::basic_string<char>, B_order*>&}'
/usr/include/c++/7/bits/unordered_map.h:584:7: note: candidate: std::pair<typename std::_Hashtable<_Key, std::pair<const _Key, _Tp>, _Alloc, std::__detail::_Select1st, _Pred, _Hash, std::__detail::_Mod_range_hashing, std::__detail::_Default_ranged_hash, std::__detail::_Prime_rehash_policy, std::__detail::_Hashtable_traits<std::__not_<std::__and_<std::__is_fast_hash<_Hash>, std::__detail::__is_noexcept_hash<_Key, _Hash> > >::value, false, true> >::iterator, bool> std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::insert(std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::value_type&&) [with _Key = std::__cxx11::basic_string<char>; _Tp = B_order*; _Hash = std::hash<std::__cxx11::basic_string<char> >; _Pred = std::equal_to<std::__cxx11::basic_string<char> >; _Alloc = std::allocator<std::pair<const std::__cxx11::basic_string<char>, B_order*> >; typename std::_Hashtable<_Key, std::pair<const _Key, _Tp>, _Alloc, std::__detail::_Select1st, _Pred, _Hash, std::__detail::_Mod_range_hashing, std::__detail::_Default_ranged_hash, std::__detail::_Prime_rehash_policy, std::__detail::_Hashtable_traits<std::__not_<std::__and_<std::__is_fast_hash<_Hash>, std::__detail::__is_noexcept_hash<_Key, _Hash> > >::value, false, true> >::iterator = std::__detail::_Node_iterator<std::pair<const std::__cxx11::basic_string<char>, B_order*>, false, true>; std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::value_type = std::pair<const std::__cxx11::basic_string<char>, B_order*>]
insert(value_type&& __x)
^~~~~~
/usr/include/c++/7/bits/unordered_map.h:584:7: note: no known conversion for argument 1 from '<brace-enclosed initializer list>' to 'std::unordered_map<std::__cxx11::basic_string<char>, B_order*>::value_type&& {aka std::pair<const std::__cxx11::basic_string<char>, B_order*>&&}'
/usr/include/c++/7/bits/unordered_map.h:591:2: note: candidate: template<class _Pair, class> std::pair<typename std::_Hashtable<_Key, std::pair<const _Key, _Tp>, _Alloc, std::__detail::_Select1st, _Pred, _Hash, std::__detail::_Mod_range_hashing, std::__detail::_Default_ranged_hash, std::__detail::_Prime_rehash_policy, std::__detail::_Hashtable_traits<std::__not_<std::__and_<std::__is_fast_hash<_Hash>, std::__detail::__is_noexcept_hash<_Key, _Hash> > >::value, false, true> >::iterator, bool> std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::insert(_Pair&&) [with _Pair = _Pair; <template-parameter-2-2> = <template-parameter-1-2>; _Key = std::__cxx11::basic_string<char>; _Tp = B_order*; _Hash = std::hash<std::__cxx11::basic_string<char> >; _Pred = std::equal_to<std::__cxx11::basic_string<char> >; _Alloc = std::allocator<std::pair<const std::__cxx11::basic_string<char>, B_order*> >]
insert(_Pair&& __x)
^~~~~~
/usr/include/c++/7/bits/unordered_map.h:591:2: note: template argument deduction/substitution failed:
main.cpp:177:47: note: couldn't deduce template parameter '_Pair'
iter3=ordersMap.insert({name,b_order}).first;
^
In file included from /usr/include/c++/7/unordered_map:48:0,
from main.cpp:8:
/usr/include/c++/7/bits/unordered_map.h:618:7: note: candidate: std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::iterator std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::insert(std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::const_iterator, const value_type&) [with _Key = std::__cxx11::basic_string<char>; _Tp = B_order*; _Hash = std::hash<std::__cxx11::basic_string<char> >; _Pred = std::equal_to<std::__cxx11::basic_string<char> >; _Alloc = std::allocator<std::pair<const std::__cxx11::basic_string<char>, B_order*> >; std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::iterator = std::__detail::_Node_iterator<std::pair<const std::__cxx11::basic_string<char>, B_order*>, false, true>; std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::const_iterator = std::__detail::_Node_const_iterator<std::pair<const std::__cxx11::basic_string<char>, B_order*>, false, true>; std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::value_type = std::pair<const std::__cxx11::basic_string<char>, B_order*>]
insert(const_iterator __hint, const value_type& __x)
^~~~~~
/usr/include/c++/7/bits/unordered_map.h:618:7: note: candidate expects 2 arguments, 1 provided
/usr/include/c++/7/bits/unordered_map.h:624:7: note: candidate: std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::iterator std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::insert(std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::const_iterator, std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::value_type&&) [with _Key = std::__cxx11::basic_string<char>; _Tp = B_order*; _Hash = std::hash<std::__cxx11::basic_string<char> >; _Pred = std::equal_to<std::__cxx11::basic_string<char> >; _Alloc = std::allocator<std::pair<const std::__cxx11::basic_string<char>, B_order*> >; std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::iterator = std::__detail::_Node_iterator<std::pair<const std::__cxx11::basic_string<char>, B_order*>, false, true>; std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::const_iterator = std::__detail::_Node_const_iterator<std::pair<const std::__cxx11::basic_string<char>, B_order*>, false, true>; std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::value_type = std::pair<const std::__cxx11::basic_string<char>, B_order*>]
insert(const_iterator __hint, value_type&& __x)
^~~~~~
/usr/include/c++/7/bits/unordered_map.h:624:7: note: candidate expects 2 arguments, 1 provided
/usr/include/c++/7/bits/unordered_map.h:631:2: note: candidate: template<class _Pair, class> std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::iterator std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::insert(std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::const_iterator, _Pair&&) [with _Pair = _Pair; <template-parameter-2-2> = <template-parameter-1-2>; _Key = std::__cxx11::basic_string<char>; _Tp = B_order*; _Hash = std::hash<std::__cxx11::basic_string<char> >; _Pred = std::equal_to<std::__cxx11::basic_string<char> >; _Alloc = std::allocator<std::pair<const std::__cxx11::basic_string<char>, B_order*> >]
insert(const_iterator __hint, _Pair&& __x)
^~~~~~
/usr/include/c++/7/bits/unordered_map.h:631:2: note: template argument deduction/substitution failed:
main.cpp:177:47: note: candidate expects 2 arguments, 1 provided
iter3=ordersMap.insert({name,b_order}).first;
^
In file included from /usr/include/c++/7/unordered_map:48:0,
from main.cpp:8:
/usr/include/c++/7/bits/unordered_map.h:646:2: note: candidate: template<class _InputIterator> void std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::insert(_InputIterator, _InputIterator) [with _InputIterator = _InputIterator; _Key = std::__cxx11::basic_string<char>; _Tp = B_order*; _Hash = std::hash<std::__cxx11::basic_string<char> >; _Pred = std::equal_to<std::__cxx11::basic_string<char> >; _Alloc = std::allocator<std::pair<const std::__cxx11::basic_string<char>, B_order*> >]
insert(_InputIterator __first, _InputIterator __last)
^~~~~~
/usr/include/c++/7/bits/unordered_map.h:646:2: note: template argument deduction/substitution failed:
main.cpp:177:47: note: candidate expects 2 arguments, 1 provided
iter3=ordersMap.insert({name,b_order}).first;
^
In file included from /usr/include/c++/7/unordered_map:48:0,
from main.cpp:8:
/usr/include/c++/7/bits/unordered_map.h:657:7: note: candidate: void std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::insert(std::initializer_list<typename std::_Hashtable<_Key, std::pair<const _Key, _Tp>, _Alloc, std::__detail::_Select1st, _Pred, _Hash, std::__detail::_Mod_range_hashing, std::__detail::_Default_ranged_hash, std::__detail::_Prime_rehash_policy, std::__detail::_Hashtable_traits<std::__not_<std::__and_<std::__is_fast_hash<_Hash>, std::__detail::__is_noexcept_hash<_Key, _Hash> > >::value, false, true> >::value_type>) [with _Key = std::__cxx11::basic_string<char>; _Tp = B_order*; _Hash = std::hash<std::__cxx11::basic_string<char> >; _Pred = std::equal_to<std::__cxx11::basic_string<char> >; _Alloc = std::allocator<std::pair<const std::__cxx11::basic_string<char>, B_order*> >; typename std::_Hashtable<_Key, std::pair<const _Key, _Tp>, _Alloc, std::__detail::_Select1st, _Pred, _Hash, std::__detail::_Mod_range_hashing, std::__detail::_Default_ranged_hash, std::__detail::_Prime_rehash_policy, std::__detail::_Hashtable_traits<std::__not_<std::__and_<std::__is_fast_hash<_Hash>, std::__detail::__is_noexcept_hash<_Key, _Hash> > >::value, false, true> >::value_type = std::pair<const std::__cxx11::basic_string<char>, B_order*>]
insert(initializer_list<value_type> __l)
^~~~~~
/usr/include/c++/7/bits/unordered_map.h:657:7: note: no known conversion for argument 1 from '<brace-enclosed initializer list>' to 'std::initializer_list<std::pair<const std::__cxx11::basic_string<char>, B_order*> >'
In file included from /usr/include/x86_64-linux-gnu/c++/7/bits/c++allocator.h:33:0,
from /usr/include/c++/7/bits/allocator.h:46,
from /usr/include/c++/7/string:41,
from /usr/include/c++/7/bits/locale_classes.h:40,
from /usr/include/c++/7/bits/ios_base.h:41,
from /usr/include/c++/7/ios:42,
from /usr/include/c++/7/ostream:38,
from /usr/include/c++/7/iostream:39,
from client.h:3,
from B_order.h:4,
from main.cpp:1:
/usr/include/c++/7/ext/new_allocator.h: In instantiation of 'void __gnu_cxx::new_allocator<_Tp>::construct(_Up*, _Args&& ...) [with _Up = std::pair<const int, B_order::order*>; _Args = {B_order::order*&, int&}; _Tp = std::_Rb_tree_node<std::pair<const int, B_order::order*> >]':
/usr/include/c++/7/bits/alloc_traits.h:475:4: required from 'static void std::allocator_traits<std::allocator<_CharT> >::construct(std::allocator_traits<std::allocator<_CharT> >::allocator_type&, _Up*, _Args&& ...) [with _Up = std::pair<const int, B_order::order*>; _Args = {B_order::order*&, int&}; _Tp = std::_Rb_tree_node<std::pair<const int, B_order::order*> >; std::allocator_traits<std::allocator<_CharT> >::allocator_type = std::allocator<std::_Rb_tree_node<std::pair<const int, B_order::order*> > >]'
/usr/include/c++/7/bits/stl_tree.h:626:32: required from 'void std::_Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::_M_construct_node(std::_Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::_Link_type, _Args&& ...) [with _Args = {B_order::order*&, int&}; _Key = int; _Val = std::pair<const int, B_order::order*>; _KeyOfValue = std::_Select1st<std::pair<const int,