List Info

Thread: Re: svn commit: r587873 - /incubator/stdcxx/branches/4.2.x/tests/utilities/20.temp.buffer.mt.cpp




Re: svn commit: r587873 - /incubator/stdcxx/branches/4.2.x/tests/u tilities/20.temp.buffer.mt.cpp
country flaguser name
United States
2007-10-24 09:44:39
faridzapache.org wrote:
> Author: faridz
> Date: Wed Oct 24 05:22:17 2007
> New Revision: 587873
> 
> URL: 
http://svn.apache.org/viewvc?rev=587873&view=rev
[...]
>  -137,10 +138,10 
>  
>  #endif   // _RWSTD_INT64_T
>  
> -    std::pair<_RWSTD_INT8_T*,  std::ptrdiff_t>
buf0;
> -    std::pair<_RWSTD_INT16_T*, std::ptrdiff_t>
buf1;
> -    std::pair<_RWSTD_INT32_T*, std::ptrdiff_t>
buf2;
> -    std::pair<Type64*,         std::ptrdiff_t>
buf3;
> +    std::pair<_RWSTD_INT8_T*,  std::ptrdiff_t>
buf0 (0, 0);
> +    std::pair<_RWSTD_INT16_T*, std::ptrdiff_t>
buf1 (0, 0);
> +    std::pair<_RWSTD_INT32_T*, std::ptrdiff_t>
buf2 (0, 0);
> +    std::pair<Type64*,         std::ptrdiff_t>
buf3 (0, 0);

Why is this necessary? Shouldn't the default ctor zero out
(i.e., default-initialize) its members?

Is this is a workaround for a compiler bug? (If so, which
one?)

Martin

RE: svn commit: r587873 - /incubator/stdcxx/branches/4.2.x/tests/u tilities/20.temp.buffer.mt.cpp
country flaguser name
Belarus
2007-10-24 11:12:19
> -----Original Message-----
> From: Martin Sebor [mailto:seborroguewave.com] 
> Sent: Wednesday, October 24, 2007 5:45 PM
> To: stdcxx-devincubator.apache.org
> Subject: Re: svn commit: r587873 - 
>
/incubator/stdcxx/branches/4.2.x/tests/utilities/20.temp.buf
fer.mt.cpp
> 
> faridzapache.org wrote:
> > Author: faridz
> > Date: Wed Oct 24 05:22:17 2007
> > New Revision: 587873
> > 
> > URL: 
http://svn.apache.org/viewvc?rev=587873&view=rev
> [...]
> >  -137,10 +138,10 
> >  
> >  #endif   // _RWSTD_INT64_T
> >  
> > -    std::pair<_RWSTD_INT8_T*, 
std::ptrdiff_t> buf0;
> > -    std::pair<_RWSTD_INT16_T*,
std::ptrdiff_t> buf1;
> > -    std::pair<_RWSTD_INT32_T*,
std::ptrdiff_t> buf2;
> > -    std::pair<Type64*,        
std::ptrdiff_t> buf3;
> > +    std::pair<_RWSTD_INT8_T*, 
std::ptrdiff_t> buf0 (0, 0);
> > +    std::pair<_RWSTD_INT16_T*,
std::ptrdiff_t> buf1 (0, 0);
> > +    std::pair<_RWSTD_INT32_T*,
std::ptrdiff_t> buf2 (0, 0);
> > +    std::pair<Type64*,        
std::ptrdiff_t> buf3 (0, 0);
> 
> Why is this necessary? Shouldn't the default ctor zero
out 
> (i.e., default-initialize) its members?
> Is this is a workaround for a compiler bug? (If so,
which one?)

  I think it was "just for sure".

  Reverted back thus:
http://svn.apache.org/viewvc?view=rev&revision=5879
09

Farid.

[1-2]

about | contact  Other archives ( Real Estate discussion Medical topics )