Skip to content
This repository has been archived by the owner on Jun 28, 2022. It is now read-only.

Compilation Error #32

Closed
Legit4K opened this issue Nov 30, 2019 · 7 comments
Closed

Compilation Error #32

Legit4K opened this issue Nov 30, 2019 · 7 comments

Comments

@Legit4K
Copy link

Legit4K commented Nov 30, 2019

There are some issues with the bear mod, it won't compile, even with default source code

@ghost
Copy link

ghost commented Nov 30, 2019 via email

@Legit4K
Copy link
Author

Legit4K commented Dec 1, 2019

In file included from /usr/include/c++/7/bits/hashtable.h:35:0,                            from /usr/include/c++/7/unordered_map:47,                                 from bear.cpp:10:                                        /usr/include/c++/7/bits/hashtable_policy.h: In instantiation of 'struct std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> >':                                                                     /usr/include/c++/7/type_traits:143:12:   required from 'struct std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > >'               /usr/include/c++/7/type_traits:154:31:   required from 'struct std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >' /usr/include/c++/7/bits/unordered_map.h:103:66:   required from 'class std::unordered_map<InventorySource, std::vector<InventoryAction> >'          bear.cpp:358:17:   required from here                                     /usr/include/c++/7/bits/hashtable_policy.h:87:34: error: no match for call to '(const std::hash<InventorySource>) (const InventorySource&)'           noexcept(declval<const _Hash&>()(declval<const _Key&>()))>                         ~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~                In file included from /usr/include/c++/7/bits/move.h:54:0,                                 from /usr/include/c++/7/bits/stl_pair.h:59,                               from /usr/include/c++/7/bits/stl_algobase.h:64,                           from /usr/include/c++/7/list:60,                                          from bear.cpp:7:                                         /usr/include/c++/7/type_traits: In instantiation of 'struct std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >':   /usr/include/c++/7/bits/unordered_map.h:103:66:   required from 'class std::unordered_map<InventorySource, std::vector<InventoryAction> >'          bear.cpp:358:17:   required from here                                     /usr/include/c++/7/type_traits:154:31: error: 'value' is not a member of 'std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > >'         : public __bool_constant<!bool(_Pp::value)>                                                         ^~~~~~~~~~~~~~~~                           In file included from /usr/include/c++/7/unordered_map:48:0,                               from bear.cpp:10:                                        /usr/include/c++/7/bits/unordered_map.h: In instantiation of 'class std::unordered_map<InventorySource, std::vector<InventoryAction> >':            bear.cpp:358:17:   required from here                                     /usr/include/c++/7/bits/unordered_map.h:103:66: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                           typedef __umap_hashtable<_Key, _Tp, _Hash, _Pred, _Alloc>  _Hashtable;                                                               ^~~~~~~~~~ /usr/include/c++/7/bits/unordered_map.h:110:45: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                              typedef typename _Hashtable::key_type key_type;                                                                 ^~~~~~~~                     /usr/include/c++/7/bits/unordered_map.h:111:47: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                              typedef typename _Hashtable::value_type value_type;                                                               ^~~~~~~~~~                 /usr/include/c++/7/bits/unordered_map.h:112:48: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                              typedef typename _Hashtable::mapped_type mapped_type;                                                              ^~~~~~~~~~~               /usr/include/c++/7/bits/unordered_map.h:113:43: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                              typedef typename _Hashtable::hasher hasher;                                                                   ^~~~~~                         /usr/include/c++/7/bits/unordered_map.h:114:46: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                              typedef typename _Hashtable::key_equal key_equal;                                                                ^~~~~~~~~                   /usr/include/c++/7/bits/unordered_map.h:115:51: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                              typedef typename _Hashtable::allocator_type allocator_type;                                                           ^~~~~~~~~~~~~~         /usr/include/c++/7/bits/unordered_map.h:120:45: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                              typedef typename _Hashtable::pointer  pointer;                                                                  ^~~~~~~                      /usr/include/c++/7/bits/unordered_map.h:121:50: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                              typedef typename _Hashtable::const_pointer const_pointer;                                                            ^~~~~~~~~~~~~           /usr/include/c++/7/bits/unordered_map.h:122:47: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                              typedef typename _Hashtable::reference  reference;                                                                ^~~~~~~~~                  /usr/include/c++/7/bits/unordered_map.h:123:52: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                              typedef typename _Hashtable::const_reference const_reference;                                                          ^~~~~~~~~~~~~~~       /usr/include/c++/7/bits/unordered_map.h:124:46: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                              typedef typename _Hashtable::iterator  iterator;                                                                 ^~~~~~~~                    /usr/include/c++/7/bits/unordered_map.h:125:51: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                              typedef typename _Hashtable::const_iterator const_iterator;                                                           ^~~~~~~~~~~~~~         /usr/include/c++/7/bits/unordered_map.h:126:51: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                              typedef typename _Hashtable::local_iterator local_iterator;                                                           ^~~~~~~~~~~~~~         /usr/include/c++/7/bits/unordered_map.h:127:57: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                              typedef typename _Hashtable::const_local_iterator const_local_iterator;                                                                                                                               ^~~~~~~~~~~~~~~~~~~~                                                                       /usr/include/c++/7/bits/unordered_map.h:128:47: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                              typedef typename _Hashtable::size_type  size_type;                                                                ^~~~~~~~~                  /usr/include/c++/7/bits/unordered_map.h:129:52: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                              typedef typename _Hashtable::difference_type difference_type;                                                          ^~~~~~~~~~~~~~~       /usr/include/c++/7/bits/unordered_map.h:133:55: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                              using node_type = typename _Hashtable::node_type;                                                                         ^                  /usr/include/c++/7/bits/unordered_map.h:134:73: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                              using insert_return_type = typename _Hashtable::insert_return_type;                                                                         ^/usr/include/c++/7/bits/unordered_map.h:288:7: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                               operator=(initializer_list<value_type> __l)                               ^~~~~~~~                                                           /usr/include/c++/7/bits/unordered_map.h:386:2: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                          emplace(_Args&&... __args)                                                ^~~~~~~                                                                 /usr/include/c++/7/bits/unordered_map.h:469:9: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                                 try_emplace(const key_type& __k, _Args&&... __args)                       ^~~~~~~~~~~                                                      /usr/include/c++/7/bits/unordered_map.h:487:9: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                                 try_emplace(key_type&& __k, _Args&&... __args)                            ^~~~~~~~~~~                                                      /usr/include/c++/7/bits/unordered_map.h:578:7: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                               insert(const value_type& __x)                                             ^~~~~~                                                             /usr/include/c++/7/bits/unordered_map.h:584:7: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                               insert(value_type&& __x)                                                  ^~~~~~                                                             /usr/include/c++/7/bits/unordered_map.h:590:2: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                          insert(_Pair&& __x)                                                       ^~~~~~                                                                  /usr/include/c++/7/bits/unordered_map.h:628:2: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                          insert(const_iterator __hint, _Pair&& __x)                                ^~~~~~                                                                  /usr/include/c++/7/bits/unordered_map.h:654:7: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                               insert(initializer_list<value_type> __l)                                  ^~~~~~                                                             /usr/include/c++/7/bits/unordered_map.h:682:9: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                                 insert_or_assign(const key_type& __k, _Obj&& __obj)                       ^~~~~~~~~~~~~~~~                                                 /usr/include/c++/7/bits/unordered_map.h:700:9: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                                 insert_or_assign(key_type&& __k, _Obj&& __obj)                            ^~~~~~~~~~~~~~~~                                                 /usr/include/c++/7/bits/unordered_map.h:950:7: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                               equal_range(const key_type& __x)                                          ^~~~~~~~~~~                                                        /usr/include/c++/7/bits/unordered_map.h:954:7: error: 'value' is not a member of 'std::__not_<std::__and_<std::__is_fast_hash<std::hash<InventorySource> >, std::__detail::__is_noexcept_hash<InventorySource, std::hash<InventorySource> > > >'                                                               equal_range(const key_type& __x) const                                    ^~~~~~~~~~~                                                        bear.cpp: In static member function 'static long unsigned int _TStaticHook__ZNK20InventoryTransaction11executeFullER6Playerb::_hook(void*, Player&, bool)':                                                                   bear.cpp:358:17: error: no matching function for call to 'begin(std::unordered_map<InventorySource, std::vector<InventoryAction> >&)'                    for(auto& i:a){                                                                       ^                                                        In file included from /usr/include/c++/7/list:62:0,                                        from bear.cpp:7:                                         /usr/include/c++/7/bits/range_access.h:105:37: note: candidate: template<class _Tp> const _Tp* std::begin(const std::valarray<_Tp>&)
   template<typename _Tp> const _Tp* begin(const valarray<_Tp>&);                                              ^~~~~                                /usr/include/c++/7/bits/range_access.h:105:37: note:   template argument deduction/substitution failed:
bear.cpp:358:17: note:   'std::unordered_map<InventorySource, std::vector<InventoryAction> >' is not derived from 'const std::valarray<_Tp>'             for(auto& i:a){                                                                       ^                                                        In file included from /usr/include/c++/7/list:62:0,                                        from bear.cpp:7:                                         /usr/include/c++/7/bits/range_access.h:104:31: note: candidate: template<class _Tp> _Tp* std::begin(std::valarray<_Tp>&)
   template<typename _Tp> _Tp* begin(valarray<_Tp>&);                                                    ^~~~~                                      /usr/include/c++/7/bits/range_access.h:104:31: note:   template argument deduction/substitution failed:
bear.cpp:358:17: note:   'std::unordered_map<InventorySource, std::vector<InventoryAction> >' is not derived from 'std::valarray<_Tp>'                   for(auto& i:a){                                                                       ^                                                        In file included from /usr/include/c++/7/list:62:0,                                        from bear.cpp:7:                                         /usr/include/c++/7/bits/range_access.h:87:5: note: candidate: template<class _Tp, long unsigned int _Nm> constexpr _Tp* std::begin(_Tp (&)[_Nm])
     begin(_Tp (&__arr)[_Nm])                                                  ^~~~~                                                                /usr/include/c++/7/bits/range_access.h:87:5: note:   template argument deduction/substitution failed:
bear.cpp:358:17: note:   mismatched types '_Tp [_Nm]' and 'std::unordered_map<InventorySource, std::vector<InventoryAction> >'                           for(auto& i:a){                                                                       ^                                                        In file included from /usr/include/c++/7/list:62:0,                                        from bear.cpp:7:                                         /usr/include/c++/7/bits/range_access.h:58:5: note: candidate: template<class _Container> constexpr decltype (__cont.begin()) std::begin(const _Container&)
     begin(const _Container& __cont) -> decltype(__cont.begin())               ^~~~~                                                                /usr/include/c++/7/bits/range_access.h:58:5: note:   template argument deduction/substitution failed:
/usr/include/c++/7/bits/range_access.h: In substitution of 'template<class _Container> constexpr decltype (__cont.begin()) std::begin(const _Container&) [with _Container = std::unordered_map<InventorySource, std::vector<InventoryAction> >]':                                                       bear.cpp:358:17:   required from here                                     /usr/include/c++/7/bits/range_access.h:58:56: error: 'const class std::unordered_map<InventorySource, std::vector<InventoryAction> >' has no member named 'begin'                                                                  begin(const _Container& __cont) -> decltype(__cont.begin())                                                           ~~~~~~~^~~~~             /usr/include/c++/7/bits/range_access.h:48:5: note: candidate: template<class _Container> constexpr decltype (__cont.begin()) std::begin(_Container&)     begin(_Container& __cont) -> decltype(__cont.begin())                     ^~~~~                                                                /usr/include/c++/7/bits/range_access.h:48:5: note:   template argument deduction/substitution failed:
/usr/include/c++/7/bits/range_access.h: In substitution of 'template<class _Container> constexpr decltype (__cont.begin()) std::begin(_Container&) [with _Container = std::unordered_map<InventorySource, std::vector<InventoryAction> >]':                                                             bear.cpp:358:17:   required from here                                     /usr/include/c++/7/bits/range_access.h:48:50: error: 'class std::unordered_map<InventorySource, std::vector<InventoryAction> >' has no member named 'begin'                                                                        begin(_Container& __cont) -> decltype(__cont.begin())                                                           ~~~~~~~^~~~~                   In file included from /usr/include/c++/7/bits/range_access.h:36:0,                         from /usr/include/c++/7/list:62,                                          from bear.cpp:7:                                         /usr/include/c++/7/initializer_list:89:5: note: candidate: template<class _Tp> constexpr const _Tp* std::begin(std::initializer_list<_Tp>)
     begin(initializer_list<_Tp> __ils) noexcept                               ^~~~~                                                                /usr/include/c++/7/initializer_list:89:5: note:   template argument deduction/substitution failed:
bear.cpp:358:17: note:   'std::unordered_map<InventorySource, std::vector<InventoryAction> >' is not derived from 'std::initializer_list<_Tp>'           for(auto& i:a){                                                                       ^                                                        bear.cpp:358:17: error: no matching function for call to 'end(std::unordered_map<InventorySource, std::vector<InventoryAction> >&)'                 In file included from /usr/include/c++/7/list:62:0,                                        from bear.cpp:7:                                         /usr/include/c++/7/bits/range_access.h:107:37: note: candidate: template<class _Tp> const _Tp* std::end(const std::valarray<_Tp>&)
   template<typename _Tp> const _Tp* end(const valarray<_Tp>&);                                                ^~~                                  /usr/include/c++/7/bits/range_access.h:107:37: note:   template argument deduction/substitution failed:
bear.cpp:358:17: note:   'std::unordered_map<InventorySource, std::vector<InventoryAction> >' is not derived from 'const std::valarray<_Tp>'             for(auto& i:a){                                                                       ^                                                        In file included from /usr/include/c++/7/list:62:0,                                        from bear.cpp:7:                                         /usr/include/c++/7/bits/range_access.h:106:31: note: candidate: template<class _Tp> _Tp* std::end(std::valarray<_Tp>&)
   template<typename _Tp> _Tp* end(valarray<_Tp>&);                                                      ^~~                                        /usr/include/c++/7/bits/range_access.h:106:31: note:   template argument deduction/substitution failed:
bear.cpp:358:17: note:   'std::unordered_map<InventorySource, std::vector<InventoryAction> >' is not derived from 'std::valarray<_Tp>'                   for(auto& i:a){                                                                       ^                                                        In file included from /usr/include/c++/7/list:62:0,                                        from bear.cpp:7:                                         /usr/include/c++/7/bits/range_access.h:97:5: note: candidate: template<class _Tp, long unsigned int _Nm> constexpr _Tp* std::end(_Tp (&)[_Nm])
     end(_Tp (&__arr)[_Nm])                                                    ^~~                                                                  /usr/include/c++/7/bits/range_access.h:97:5: note:   template argument deduction/substitution failed:
bear.cpp:358:17: note:   mismatched types '_Tp [_Nm]' and 'std::unordered_map<InventorySource, std::vector<InventoryAction> >'                           for(auto& i:a){                                                                       ^                                                        In file included from /usr/include/c++/7/list:62:0,                                        from bear.cpp:7:                                         /usr/include/c++/7/bits/range_access.h:78:5: note: candidate: template<class _Container> constexpr decltype (__cont.end()) std::end(const _Container&)
     end(const _Container& __cont) -> decltype(__cont.end())                   ^~~                                                                  /usr/include/c++/7/bits/range_access.h:78:5: note:   template argument deduction/substitution failed:
/usr/include/c++/7/bits/range_access.h: In substitution of 'template<class _Container> constexpr decltype (__cont.end()) std::end(const _Container&) [with _Container = std::unordered_map<InventorySource, std::vector<InventoryAction> >]':                                                           bear.cpp:358:17:   required from here                                     /usr/include/c++/7/bits/range_access.h:78:54: error: 'const class std::unordered_map<InventorySource, std::vector<InventoryAction> >' has no member named 'end'                                                                    end(const _Container& __cont) -> decltype(__cont.end())                                                             ~~~~~~~^~~                 /usr/include/c++/7/bits/range_access.h:68:5: note: candidate: template<class _Container> constexpr decltype (__cont.end()) std::end(_Container&)
     end(_Container& __cont) -> decltype(__cont.end())                         ^~~                                                                  /usr/include/c++/7/bits/range_access.h:68:5: note:   template argument deduction/substitution failed:
/usr/include/c++/7/bits/range_access.h: In substitution of 'template<class _Container> constexpr decltype (__cont.end()) std::end(_Container&) [with _Container = std::unordered_map<InventorySource, std::vector<InventoryAction> >]':                                                                 bear.cpp:358:17:   required from here                                     /usr/include/c++/7/bits/range_access.h:68:48: error: 'class std::unordered_map<InventorySource, std::vector<InventoryAction> >' has no member named 'end'                                                                          end(_Container& __cont) -> decltype(__cont.end())                                                             ~~~~~~~^~~                       In file included from /usr/include/c++/7/bits/range_access.h:36:0,                         from /usr/include/c++/7/list:62,                                          from bear.cpp:7:                                         /usr/include/c++/7/initializer_list:99:5: note: candidate: template<class _Tp> constexpr const _Tp* std::end(std::initializer_list<_Tp>)
     end(initializer_list<_Tp> __ils) noexcept                                 ^~~                                                                  /usr/include/c++/7/initializer_list:99:5: note:   template argument deduction/substitution failed:
bear.cpp:358:17: note:   'std::unordered_map<InventorySource, std::vector<InventoryAction> >' is not derived from 'std::initializer_list<_Tp>'           for(auto& i:a){                                                                       ^                                                        In file included from bear.cpp:16:0:                                      ../../include/seral.hpp: In function 'void mem2file(const char*, char*, int, bool)':                                                                ../../include/seral.hpp:114:10: warning: ignoring return value of 'ssize_t write(int, const void*, size_t)', declared with attribute warn_unused_result [-Wunused-result]                                                          write(fd,mem,sz);                                                         ~~~~~^~~~~~~~~~~                                                     bear.cpp: In function 'void async_log(const char*, ...)':                 bear.cpp:102:10: warning: ignoring return value of 'ssize_t write(int, const void*, size_t)', declared with attribute warn_unused_result [-Wunused-result]                                                                         write(1,buf,s);                                                           ~~~~~^~~~~~~~~                                                       bear.cpp:103:10: warning: ignoring return value of 'ssize_t write(int, const void*, size_t)', declared with attribute warn_unused_result [-Wunused-result]                                                                         write(logfd,buf,s);                                                       ~~~~~^~~~~~~~~~~~~                                                   In file included from bear.cpp:16:0:                                      ../../include/seral.hpp: In function 'void file2mem(const char*, char**, int&)':                                                                    ../../include/seral.hpp:124:10: warning: ignoring return value of 'size_t fread(void*, size_t, size_t, FILE*)', declared with attribute warn_unused_result [-Wunused-result]                                                       fread(*mem,sz,1,fp);                                                      ~~~~~^~~~~~~~~~~~~~

@KawaiiNahida
Copy link
Collaborator

KawaiiNahida commented Dec 1, 2019

May be you can update g++?
It work well on my machine
IMG_20191201_083531

@Legit4K
Copy link
Author

Legit4K commented Dec 1, 2019

g++ (Ubuntu 7.4.0-1ubuntu1~18.04.1) 7.4.0�������

Is this version compatible?

@KawaiiNahida
Copy link
Collaborator

╭─water@WDMC /mc/sur/bdlauncher/mod/bear ‹master*› ╰─$ g++ -v Using built-in specs. COLLECT_GCC=g++ COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-linux-gnu/9/lto-wrapper OFFLOAD_TARGET_NAMES=nvptx-none:hsa OFFLOAD_TARGET_DEFAULT=1 Target: x86_64-linux-gnu Configured with: ../src/configure -v --with-pkgversion='Ubuntu 9.2.1-9ubuntu2' --with-bugurl=file:///usr/share/doc/gcc-9/README.Bugs --enable-languages=c,ada,c++,go,brig,d,fortran,objc,obj-c++,gm2 --prefix=/usr --with-gcc-major-version-only --program-suffix=-9 --program-prefix=x86_64-linux-gnu- --enable-shared --enable-linker-build-id --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --libdir=/usr/lib --enable-nls --enable-bootstrap --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --with-default-libstdcxx-abi=new --enable-gnu-unique-object --disable-vtable-verify --enable-plugin --enable-default-pie --with-system-zlib --with-target-system-zlib=auto --enable-multiarch --disable-werror --with-arch-32=i686 --with-abi=m64 --with-multilib-list=m32,m64,mx32 --enable-multilib --with-tune=generic --enable-offload-targets=nvptx-none,hsa --without-cuda-driver --enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu --target=x86_64-linux-gnu Thread model: posix gcc version 9.2.1 20191008 (Ubuntu 9.2.1-9ubuntu2)

@KawaiiNahida
Copy link
Collaborator

You may need to run
apt update && apt upgrade

@Legit4K
Copy link
Author

Legit4K commented Dec 1, 2019

It didn't seem to update but I managed to add the toolchain PPA and switched to g++ 9 & gcc 9 and now it works, thanks!

@Legit4K Legit4K closed this as completed Dec 1, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants