[cfe-commits] [PATCH] Fixing constant default initialization with explicitly defaulted constructors

Aaron Ballman aaron at aaronballman.com
Tue Jul 31 15:41:26 PDT 2012


Thanks, committed in r161088

~Aaron

On Tue, Jul 31, 2012 at 6:32 PM, Richard Smith <richard at metafoo.co.uk> wrote:
> LGTM, thanks!
>
>
> On Tue, Jul 31, 2012 at 3:25 PM, Aaron Ballman <aaron at aaronballman.com>
> wrote:
>>
>> This patch addresses PR13492 and PR13216, where explicitly defaulted
>> constructors were allowed during default initialization of a constant.
>>  For instance:
>>
>>   struct B {
>>     B() = default;
>>   };
>>
>>   void f() {
>>     const B b;  // Should error
>>   }
>>
>> It did catch some problems with previous test cases that I've also
>> corrected.
>>
>> ~Aaron
>
>



More information about the cfe-commits mailing list