[cfe-commits] [PATCH] Fixed scoped enum name conflicts

Aaron Ballman aaron at aaronballman.com
Wed Jul 18 20:16:03 PDT 2012


On Wed, Jul 18, 2012 at 9:57 PM, Richard Smith <richard at metafoo.co.uk> wrote:
> On Wed, Jul 18, 2012 at 7:51 PM, Aaron Ballman <aaron at aaronballman.com>
> wrote:
>>
>> This patch addresses PR13128, which points out that the scoped enum
>> constant name lookup still causes errors when conflicting with the
>> class name.  Due to it being a scoped enum, the name is looked up in
>> scope, and so the class name doesn't provide a conflict with the
>> following example:
>>
>> class C {
>>   enum class E { C };
>> };
>
>
> Please update the comment above your change with the relevant quotation from
> C++11 [class.mem]p15. Otherwise, LGTM

Thanks for the quick review!  It's in r160490, along with your suggested change.

~Aaron



More information about the cfe-commits mailing list