Page MenuHomePhabricator

ratscript error
ActivePublic

Authored by ardunster on Mar 5 2021, 1:20 PM.
In file included from /home/anna/Documents/MousePaw/repos/ratscript/ratscript-source/src/lexer.cpp:1:
In file included from /home/anna/Documents/MousePaw/repos/ratscript/ratscript-source/include/ratscript/lexer.hpp:64:
In file included from /home/anna/Documents/MousePaw/repos/ratscript/ratscript-source/../../nimbly/nimbly/include/nimbly/flexarray.hpp:53:
In file included from /home/anna/Documents/MousePaw/repos/ratscript/ratscript-source/../../iosqueak/iosqueak/include/iosqueak/channel.hpp:87:
In file included from /home/anna/Documents/MousePaw/repos/ratscript/ratscript-source/../../libdeps/libs/include/eventpp/callbacklist.h:17:
In file included from /home/anna/Documents/MousePaw/repos/ratscript/ratscript-source/../../libdeps/libs/include/eventpp/eventpolicies.h:23:
In file included from /usr/bin/../lib/gcc/x86_64-linux-gnu/9/../../../../include/c++/9/unordered_map:46:
In file included from /usr/bin/../lib/gcc/x86_64-linux-gnu/9/../../../../include/c++/9/bits/hashtable.h:35:
/usr/bin/../lib/gcc/x86_64-linux-gnu/9/../../../../include/c++/9/bits/hashtable_policy.h:1382:2: error: static_assert failed due to requirement 'std::__is_invocable<const std::hash<onestring> &, const onestring &>{}' "hash function must be invocable with an argument of key type"
static_assert(__is_invocable<const _H1&, const _Key&>{},
^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/bin/../lib/gcc/x86_64-linux-gnu/9/../../../../include/c++/9/bits/hashtable.h:1449:34: note: in instantiation of member function 'std::__detail::_Hash_code_base<onestring, std::pair<const onestring, TokenType>, std::__detail::_Select1st, std::hash<onestring>, std::__detail::_Mod_range_hashing, std::__detail::_Default_ranged_hash, true>::_M_hash_code' requested here
__hash_code __code = this->_M_hash_code(__k);
^
/usr/bin/../lib/gcc/x86_64-linux-gnu/9/../../../../include/c++/9/bits/unordered_map.h:939:21: note: in instantiation of member function 'std::_Hashtable<onestring, std::pair<const onestring, TokenType>, std::allocator<std::pair<const onestring, TokenType> >, std::__detail::_Select1st, std::equal_to<onestring>, std::hash<onestring>, std::__detail::_Mod_range_hashing, std::__detail::_Default_ranged_hash, std::__detail::_Prime_rehash_policy, std::__detail::_Hashtable_traits<true, false, true> >::count' requested here
{ return _M_h.count(__x); }
^
/home/anna/Documents/MousePaw/repos/ratscript/ratscript-source/src/lexer.cpp:178:36: note: in instantiation of member function 'std::unordered_map<onestring, TokenType, std::hash<onestring>, std::equal_to<onestring>, std::allocator<std::pair<const onestring, TokenType> > >::count' requested here
channel << keyword_string_to_type.count(lexeme) << IOCat::debug << IOCtrl::endl;
^
In file included from /home/anna/Documents/MousePaw/repos/ratscript/ratscript-source/src/lexer.cpp:1:
In file included from /home/anna/Documents/MousePaw/repos/ratscript/ratscript-source/include/ratscript/lexer.hpp:64:
In file included from /home/anna/Documents/MousePaw/repos/ratscript/ratscript-source/../../nimbly/nimbly/include/nimbly/flexarray.hpp:53:
In file included from /home/anna/Documents/MousePaw/repos/ratscript/ratscript-source/../../iosqueak/iosqueak/include/iosqueak/channel.hpp:87:
In file included from /home/anna/Documents/MousePaw/repos/ratscript/ratscript-source/../../libdeps/libs/include/eventpp/callbacklist.h:17:
In file included from /home/anna/Documents/MousePaw/repos/ratscript/ratscript-source/../../libdeps/libs/include/eventpp/eventpolicies.h:23:
In file included from /usr/bin/../lib/gcc/x86_64-linux-gnu/9/../../../../include/c++/9/unordered_map:46:
In file included from /usr/bin/../lib/gcc/x86_64-linux-gnu/9/../../../../include/c++/9/bits/hashtable.h:35:
/usr/bin/../lib/gcc/x86_64-linux-gnu/9/../../../../include/c++/9/bits/hashtable_policy.h:1384:9: error: type 'const std::hash<onestring>' does not provide a call operator
return _M_h1()(__k);
^~~~~~~
2 errors generated.
make[4]: *** [CMakeFiles/ratscript.dir/build.make:63: CMakeFiles/ratscript.dir/src/lexer.cpp.o] Error 1
make[4]: Leaving directory '/home/anna/Documents/MousePaw/repos/ratscript/ratscript-source/build_temp/Release'
make[3]: *** [CMakeFiles/Makefile2:76: CMakeFiles/ratscript.dir/all] Error 2
make[3]: Leaving directory '/home/anna/Documents/MousePaw/repos/ratscript/ratscript-source/build_temp/Release'
make[2]: *** [Makefile:84: all] Error 2
make[2]: Leaving directory '/home/anna/Documents/MousePaw/repos/ratscript/ratscript-source/build_temp/Release'
make[1]: *** [../build_system/inner.mk:105: release] Error 2
make[1]: Leaving directory '/home/anna/Documents/MousePaw/repos/ratscript/ratscript-source'
make: *** [build_system/outer.mk:125: ratscript] Error 2