Boost logo

Boost :

From: Peter Dimov (pdimov_at_[hidden])
Date: 2002-11-19 11:40:19


Borland C++ 5.5.1 fails the following test:

struct X
{
    X(): next() {}
    boost::shared_ptr<X> next;
};

void test()
{
    boost::shared_ptr<X> p(new X);
    p->next = boost::shared_ptr<X>(new X);
    BOOST_TEST(!p->next->next);
    p = p->next;
    BOOST_TEST(!p->next); // here
}

The other test cases (and there are lots!) pass, and the above passes with
my other compilers. Any insights are appreciated.

--
Peter Dimov
http://www.pdimov.com

Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk