[cfe-commits] Request for approval: Pythonstuff including Cursor.enum_value
klimek at google.com
Wed May 2 11:29:05 PDT 2012
On Wed, May 2, 2012 at 8:16 PM, Gregory Szorc <gregory.szorc at gmail.com> wrote:
> On 5/2/12 10:47 AM, Manuel Klimek wrote:
>> Regarding patch 0005:
>> + def enum_value(self):
>> + """Return the value of an enum constant."""
>> + if not hasattr(self, '_enum_value'):
>> + assert self.kind == CursorKind.ENUM_CONSTANT_DECL
>> + typ = self.type
>> Is there a reason to call it "typ" instead of "type"?
> "type" is a builtin class.
Yea, we should probably not shadow that...
Call it underlying_type instead then? That would also document the intention...
More information about the cfe-commits