Boost logo

Boost :

From: Jens Maurer (Jens.Maurer_at_[hidden])
Date: 2001-01-24 14:14:56

Gabriel Dos Reis wrote:
> That is not true. I've just tested the following with 2.95.2 (and I
> believe it to work properly with the whole 2.95.x series.

> I'am mainly concerned with your comment about std::abs. It was not
> accurate.

It was. Note that rational<T> is a template class. Please try the
following test.

namespace N1
  int f(int);

template<class T>
int g(const T& x)
  using N1::f;
  return f(x);

int main()

The gcc error message on my Linux/x86 system is:

GNU C++ version 2.95.2 19991024 (release) (i686-pc-linux-gnu) compiled by GNU C version 2.95.2 19991024 (release). In function `int g<int>(const int &)': instantiated from here `f' undeclared (first use this function) (Each undeclared identifier is reported only once for each function it appears in.)

(The code compiles without a problem with Comeau C++ 4.2.44beta3 in strict mode.)

The bug was confirmed by Martin v. Loewis, one of the gcc authors.

I've also added slightly more verbiage to boost/rational.hpp.

Jens Maurer

Boost list run by bdawes at, gregod at, cpdaniel at, john at