stdcxx-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Martin Sebor <>
Subject Re: STDCXX-615
Date Sun, 09 Mar 2008 23:12:59 GMT
Scott Zhong wrote:
> The following test case reproduces the bug:

Thanks for the test case! I sent a reduced version of it to HP.

> It seems to me that 
>> Derived<int>* const pDer = new Derived<int>;
>> my_ptr<volatile Derived<int> > ptr_0 (pDer);
>> my_ptr<volatile Base_0<int> > ptr_1 (ptr_0);
> Is essentially performing the following which doesn't cause the compiler
> error to occur:
>> Derived<int>* const pDer = new Derived<int>;
>> volatile Derived<int> *ptr_0 = pDer;
>> volatile Base_0<int> *ptr_1 = ptr_0;

Changing the test this way would defeat its purpose: to exercise
shared_ptr's ability to perform conversions between related types
with different (but compatible) cv-qualifications.

Unless you can think of a workaround that doesn't compromise the
test's efficacy, now that we have a test case that clearly shows
it's a compiler bug we can either mark the compilation failure
of test as EXPECTED in xfail.txt or disable that part of the test.


View raw message