Boost logo

Boost Users :

From: Martin Stone (yg-boost-users_at_[hidden])
Date: 2002-10-09 08:00:10


"Christopher Henrich" <chenrich_at_[hidden]> wrote:
> This bug comes up when I try to include <boost/array.hpp> in certain
> CodeWarrior projects.
...
> Error: undefined identifier 'ptrdiff_t'
...

I get this too when using Code Warrior for PlayStation2 with
<boost/smart_ptr.hpp>.

It appears that the compiler-supplied <cstddef> simply contains #include
<stddef.h>, so ptrdiff_t is not getting defined in the std namespace. Doing
this:

    namespace std{using ::ptrdiff_t;}
    #include <boost/smart_ptr.hpp>

fixes it, but I'm not sure that this is strictly allowed.

If anybody knows a better fix, please let me know.

Martin.


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