------- Additional Comments From gdr at integrable-solutions dot net 2005-01-21 02:28 ------- Subject: Re: Difference in behaviour if default constructor added
"caj at cs dot york dot ac dot uk" <[EMAIL PROTECTED]> writes: | Subject: Re: Difference in behaviour if default constructor | added | | bangerth at dealii dot org wrote: | | >------- Additional Comments From bangerth at dealii dot org 2005-01-20 20:46 ------- | >To be completely clear, the compiler generated default constructor is | > ptr() : a(0) {} | >not | > ptr() {} | >Thus, it _does_ initialize 'a'. | > | >W. | > | > | > | Sorry to be dense, but I want to follow this.. Is this a choice g++ | makes, or is it mandated by the standard? Is this defined by something | other than 12.1/7, or does 12.1/7 actually require this and I'm | misreading it? You mean when you write "ptr()" in the member initializer list? Check for value initialization in 8.5. -- Gaby -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19544