[Boost-bugs] [Boost C++ Libraries] #12006: Compile error on Windows of boost/functional/hash/extensions.hpp

Subject: [Boost-bugs] [Boost C++ Libraries] #12006: Compile error on Windows of boost/functional/hash/extensions.hpp
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2016-02-19 14:54:18


#12006: Compile error on Windows of boost/functional/hash/extensions.hpp
-----------------------------+------------------------------
 Reporter: kilian.kilger@… | Type: Bugs
   Status: new | Milestone: To Be Determined
Component: None | Version: Boost 1.58.0
 Severity: Problem | Keywords:
-----------------------------+------------------------------
 I use STLport 4.5.0 and Visual Studio 2013. I get the following compiler
 error:

 {{{
 base\boost\boost/functional/hash/extensions.hpp(262) : error C2784:
 'size_t boost::hash_value(const _STL::complex<_Tp> &)' : could not deduce
 template argument for 'const _STL::complex<_Tp> &' from 'const wchar_t'
         boost/functional/hash/extensions.hpp(64) : see declaration of
 'boost::hash_value'
         boost/functional/hash/extensions.hpp(261) : while compiling class
 template member function 'size_t boost::hash<T>::operator ()(const T &)
 const'
         with
         [
             T=wchar_t
         ]
         boost/functional/hash/hash.hpp(313) : see reference to function
 template instantiation 'size_t boost::hash<T>::operator ()(const T &)
 const' being compiled
         with
         [
             T=wchar_t
         ]
         boost/functional/hash/hash.hpp(312) : see reference to class
 template instantiation 'boost::hash<T>' being compiled
         with
         [
             T=wchar_t
         ]
         boost\boost/functional/hash/hash.hpp(327) : see reference to
 function template instantiation 'void boost::hash_combine<wchar_t>(size_t
 &,const T &)' being compiled
         with
         [
             T=wchar_t
         ]
         boost/functional/hash/hash.hpp(386) : see reference to function
 template instantiation 'size_t boost::hash_range<const wchar_t*>(It,It)'
 being compiled
         with
         [
             It=const wchar_t *
         ]
         boost/functional/hash/hash.hpp(458) : see reference to function
 template instantiation 'size_t
 boost::hash_value<wchar_t,_STL::allocator<wchar_t>>(const
 _STL::basic_string<wchar_t,_STL::char_traits<wchar_t>,_STL::allocator<wchar_t>>
 &)' being compiled
 base\boost\boost/functional/hash/extensions.hpp(262) : error C2784:
 'size_t boost::hash_value(const _STL::multimap<_Key,_Tp,_Compare,_Alloc>
 &)' : could not deduce template argument for 'const
 _STL::multimap<_Key,_Tp,_Compare,_Alloc> &' from 'const wchar_t'
         boost\boost/functional/hash/extensions.hpp(61) : see declaration
 of 'boost::hash_value'
 base\boost\boost/functional/hash/extensions.hpp(262) : error C2784:
 'size_t boost::hash_value(const _STL::map<_Key,_Tp,_Compare,_Alloc> &)' :
 could not deduce template argument for 'const
 _STL::map<_Key,_Tp,_Compare,_Alloc> &' from 'const wchar_t'
         boost\boost/functional/hash/extensions.hpp(59) : see declaration
 of 'boost::hash_value'
 base\boost\boost/functional/hash/extensions.hpp(262) : error C2784:
 'size_t boost::hash_value(const _STL::multiset<_Key,_Compare,_Alloc> &)' :
 could not deduce template argument for 'const
 _STL::multiset<_Key,_Compare,_Alloc> &' from 'const wchar_t'
         boost\boost/functional/hash/extensions.hpp(57) : see declaration
 of 'boost::hash_value'
 base\boost\boost/functional/hash/extensions.hpp(262) : error C2784:
 'size_t boost::hash_value(const _STL::set<_Key,_Compare,_Alloc> &)' :
 could not deduce template argument for 'const
 _STL::set<_Key,_Compare,_Alloc> &' from 'const wchar_t'
         boost\boost/functional/hash/extensions.hpp(55) : see declaration
 of 'boost::hash_value'
 base\boost\boost/functional/hash/extensions.hpp(262) : error C2784:
 'size_t boost::hash_value(const _STL::deque<_Tp,_Alloc> &)' : could not
 deduce template argument for 'const _STL::deque<_Tp,_Alloc> &' from 'const
 wchar_t'
         boost\boost/functional/hash/extensions.hpp(53) : see declaration
 of 'boost::hash_value'
 base\boost\boost/functional/hash/extensions.hpp(262) : error C2784:
 'size_t boost::hash_value(const _STL::list<_Tp,_Alloc> &)' : could not
 deduce template argument for 'const _STL::list<_Tp,_Alloc> &' from 'const
 wchar_t'
         boost\boost/functional/hash/extensions.hpp(51) : see declaration
 of 'boost::hash_value'
 base\boost\boost/functional/hash/extensions.hpp(262) : error C2784:
 'size_t boost::hash_value(const _STL::vector<_Tp,_Alloc> &)' : could not
 deduce template argument for 'const _STL::vector<_Tp,_Alloc> &' from
 'const wchar_t'
         boost\boost/functional/hash/extensions.hpp(49) : see declaration
 of 'boost::hash_value'
 base\boost\boost/functional/hash/extensions.hpp(262) : error C2784:
 'size_t boost::hash_value(const _STL::pair<_T1,_T2> &)' : could not deduce
 template argument for 'const _STL::pair<_T1,_T2> &' from 'const wchar_t'
         boost\boost/functional/hash/extensions.hpp(47) : see declaration
 of 'boost::hash_value'
 base\boost\boost/functional/hash/extensions.hpp(262) : error C2893: Failed
 to specialize function template
 'boost::hash_detail::float_numbers<T>::type boost::hash_value(T)'
         With the following template arguments:
         'T=wchar_t'
 base\boost\boost/functional/hash/extensions.hpp(262) : error C2784:
 'size_t boost::hash_value(const
 _STL::basic_string<Ch,_STL::char_traits<_CharT>,A> &)' : could not deduce
 template argument for 'const
 _STL::basic_string<Ch,_STL::char_traits<_CharT>,A> &' from 'const wchar_t'
         boost\boost/functional/hash/hash.hpp(154) : see declaration of
 'boost::hash_value'
 base\boost\boost/functional/hash/extensions.hpp(262) : error C2784:
 'size_t boost::hash_value(T (&)[N])' : could not deduce template argument
 for 'T (&)[N]' from 'const wchar_t'
         boost/functional/hash/hash.hpp(150) : see declaration of
 'boost::hash_value'
 base\boost\boost/functional/hash/extensions.hpp(262) : error C2784:
 'size_t boost::hash_value(const T (&)[N])' : could not deduce template
 argument for 'const T (&)[N]' from 'const wchar_t'
         boost/functional/hash/hash.hpp(147) : see declaration of
 'boost::hash_value'
 base\boost\boost/functional/hash/extensions.hpp(262) : error C2784:
 'size_t boost::hash_value(T *const &)' : could not deduce template
 argument for 'T *const &' from 'const wchar_t'
         boost/functional/hash/hash.hpp(140) : see declaration of
 'boost::hash_value'
 base\boost\boost/functional/hash/extensions.hpp(262) : error C2893: Failed
 to specialize function template
 'boost::enable_if<boost::is_enum<T>,size_t>::type boost::hash_value(T)'
         With the following template arguments:
         'T=wchar_t'
 base\boost\boost/functional/hash/extensions.hpp(262) : error C2893: Failed
 to specialize function template
 'boost::hash_detail::ulong_numbers<T>::type boost::hash_value(T)'
         With the following template arguments:
         'T=wchar_t'
 base\boost\boost/functional/hash/extensions.hpp(262) : error C2893: Failed
 to specialize function template 'boost::hash_detail::long_numbers<T>::type
 boost::hash_value(T)'
         With the following template arguments:
         'T=wchar_t'
 base\boost\boost/functional/hash/extensions.hpp(262) : error C2893: Failed
 to specialize function template
 'boost::hash_detail::basic_numbers<T>::type boost::hash_value(T)'
         With the following template arguments:
         'T=wchar_t'
 }}}

 If I set BOOST_NO_FUNCTION_TEMPLATE_ORDERING, I get a similar error.

 I don't know where they come from. With old boost versions, it worked just
 fine. Do you have any clue?

 Best regards,
 Kilian.

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/12006>
Boost C++ Libraries <http://www.boost.org/>
Boost provides free peer-reviewed portable C++ source libraries.

This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:19 UTC