Boost logo

Boost Users :

Subject: [Boost-users] [xint] Ptoblems with compiling
From: Андрей Серебро (andy.silv_at_[hidden])
Date: 2016-06-16 08:25:01


Good day, everyone!
 
I have used xint something like a year ago last time, and then I was happy with it. That time I used windows and hence cl to compile it. I don't remember the version of boost I used, but it was something yearish ago or so.
Now I have checked out my project on ubuntu machine and tried to build it with g++ 4.8.4 and boost 1.54. Unfortunately, I got following output compiling simple example from the http://www.oakcircle.com/xint_docs/ex_simplest.html

In file included from tmp.cpp:3:0:
/usr/include/boost/xint/integer.hpp: In instantiation of ‘boost::xint::integer_t<A0, A1, A2, A3, A4, A5>::integer_t(Type, typename boost::enable_if<boost::is_integral<Functor> >::type*) [with Type = int; A0 = boost::parameter::void_; A1 = boost::parameter::void_; A2 = boost::parameter::void_; A3 = boost::parameter::void_; A4 = boost::parameter::void_; A5 = boost::parameter::void_; typename boost::enable_if<boost::is_integral<Functor> >::type = void]’:
tmp.cpp:11:30: required from here
/usr/include/boost/xint/integer.hpp:479:47: error: no type named ‘_fix_negative_unsigned’ in ‘class boost::xint::detail::unsigned_negative_functions<(boost::xint::detail::negative_policy)0u, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_>’
if (!Signed && data.negative) _fix_negative_unsigned();
^
/usr/include/boost/xint/integer.hpp:487:43: error: no type named ‘_fix_negative_unsigned’ in ‘class boost::xint::detail::unsigned_negative_functions<(boost::xint::detail::negative_policy)0u, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_>’
if (!Signed && data.negative) _fix_negative_unsigned();
^
/usr/include/boost/xint/integer.hpp: In instantiation of ‘boost::xint::integer_t<A0, A1, A2, A3, A4, A5>& boost::xint::integer_t<A0, A1, A2, A3, A4, A5>::operator+=(boost::xint::integer_t<A0, A1, A2, A3, A4, A5>) [with A0 = boost::parameter::void_; A1 = boost::parameter::void_; A2 = boost::parameter::void_; A3 = boost::parameter::void_; A4 = boost::parameter::void_; A5 = boost::parameter::void_]’:
tmp.cpp:15:7: required from here
/usr/include/boost/xint/integer.hpp:569:13: error: no type named ‘is_nan’ in ‘class boost::xint::detail::nan_functions<false, boost::xint::integer_t<>, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_>’
if (!is_nan()) {
^
/usr/include/boost/xint/integer.hpp: In instantiation of ‘boost::xint::integer_t<A0, A1, A2, A3, A4, A5>& boost::xint::integer_t<A0, A1, A2, A3, A4, A5>::operator++() [with A0 = boost::parameter::void_; A1 = boost::parameter::void_; A2 = boost::parameter::void_; A3 = boost::parameter::void_; A4 = boost::parameter::void_; A5 = boost::parameter::void_]’:
tmp.cpp:17:7: required from here
/usr/include/boost/xint/integer.hpp:681:13: error: no type named ‘is_nan’ in ‘class boost::xint::detail::nan_functions<false, boost::xint::integer_t<>, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_>’
if (!is_nan()) {
^
/usr/include/boost/xint/integer.hpp: In instantiation of ‘boost::xint::integer_t<A0, A1, A2, A3, A4, A5>& boost::xint::integer_t<A0, A1, A2, A3, A4, A5>::operator*=(boost::xint::integer_t<A0, A1, A2, A3, A4, A5>) [with A0 = boost::parameter::void_; A1 = boost::parameter::void_; A2 = boost::parameter::void_; A3 = boost::parameter::void_; A4 = boost::parameter::void_; A5 = boost::parameter::void_]’:
tmp.cpp:18:7: required from here
/usr/include/boost/xint/integer.hpp:615:13: error: no type named ‘is_nan’ in ‘class boost::xint::detail::nan_functions<false, boost::xint::integer_t<>, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_>’
if (!is_nan()) {
^
/usr/include/boost/xint/integer.hpp: In instantiation of ‘boost::xint::integer_t<A0, A1, A2, A3, A4, A5>::integer_t(const charT*, std::size_t) [with charT = char; A0 = boost::parameter::void_; A1 = boost::parameter::void_; A2 = boost::parameter::void_; A3 = boost::parameter::void_; A4 = boost::parameter::void_; A5 = boost::parameter::void_; std::size_t = long unsigned int]’:
tmp.cpp:30:77: required from here
/usr/include/boost/xint/integer.hpp:272:47: error: no type named ‘_fix_negative_unsigned’ in ‘class boost::xint::detail::unsigned_negative_functions<(boost::xint::detail::negative_policy)0u, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_>’
if (!Signed && data.negative) _fix_negative_unsigned();
^
/usr/include/boost/xint/integer.hpp:279:39: error: no type named ‘_fix_negative_unsigned’ in ‘class boost::xint::detail::unsigned_negative_functions<(boost::xint::detail::negative_policy)0u, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_>’
if (!Signed && data.negative) _fix_negative_unsigned();
^

 
 
I also tried more recent boost 1.61, but then I got errors with using incomplete type integral_c<>. 
 
Can you tell me what can I do wrong? Thanks in advance.
 
-- 
Regards,
Andrei Serebro
tel. +79111758381
 

Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net