$include_dir="/home/hyper-archives/boost/include"; include("$include_dir/msg-header.inc") ?>
Subject: Re: [boost] [multiprecision review] EOF not declared, and noexcept errors
From: Christopher Kormanyos (e_float_at_[hidden])
Date: 2012-06-13 15:43:14
> I'm trying to do some simple tests with the proposed Boost.Multiprecision,
> but anything that includes e.g. boost/multiprecision/cpp_int.hpp gives errors like this:
Thanks for your efforts, Phil.
What compiler?
Which boost?
> /big_number/boost/multiprecision/mp_number.hpp:1730:11: error: âEOFâ was not declared in this scope
EOF is an old-school macro defined in <stdio.h>. It must be
in <cstdio> with C++11's C99 compatibility.
> /big_number/boost/multiprecision/rational_adapter.hpp:208:45: error: expected â;â at end of member declaration
For some strange reason, the compiler does not like (min)() --- even
with the well-known MSVC workaround of parentheses.
> /big_number/boost/multiprecision/rational_adapter.hpp:208:47: error: ânoexceptâ does not name a type
It almost seems like you might have some macros activated when they shouldn't be.
As far as I know, noexcept is C++11 and it only gets activated if BOOST_NO_NOEXCEPT
is *not* defined. BOOST_NO_NOEXCEPT subsequently defines BOOST_MP_NOEXCEPT
as nothing (empty), which is what you want.
> My guess is that the EOF error may be a missing include, while the
> latter two errors may be something that's missing in the relatively
> old Boost installation on this test machine. Can anyone suggest what I need to do?
> Regards, Phil.
Just to move forward in the diagnosis, could you please perhaps try something?
It's not the solution, but might show what's going on...
Above the #include <boost/multiprecisioni/cpp_int.hpp>
* #define EOF -1
* #define BOOST_NO_NOEXCEPT
* #undef min
* #undef maxMaybe this will shed more light on the exact situation at hand.
Best regards, Chris.