Piet van Oostrum wrote:
> Chris Angelico writes:
>
>> I'm not sure what's going on here, and it's probably not actually
>> enum-specific, but that's where I saw it.
>>
>> If you create a plain class and have an attribute with an annotation,
>> you can see that:
>>
> class Foo:
>> ...
Chris Angelico writes:
> I'm not sure what's going on here, and it's probably not actually
> enum-specific, but that's where I saw it.
>
> If you create a plain class and have an attribute with an annotation,
> you can see that:
>
class Foo:
> ... spam: "ham" = 1
> ...
Foo.__a
>
Chris Angelico wrote:
>> Looks like everything starting with an underscore (except class, doc, and
>> module) is suppressed, probably to suppress some noise...
>>
>
> That's why dir() shows what it does, but tab completion seems to have
> some other source, as it's able to find a lot of other
On Mon, Oct 7, 2019 at 6:00 PM Peter Otten <__pete...@web.de> wrote:
>
> Chris Angelico wrote:
>
> > I'm not sure what's going on here, and it's probably not actually
> > enum-specific, but that's where I saw it.
> >
> > If you create a plain class and have an attribute with an annotation,
> > you
Chris Angelico wrote:
> I'm not sure what's going on here, and it's probably not actually
> enum-specific, but that's where I saw it.
>
> If you create a plain class and have an attribute with an annotation,
> you can see that:
>
class Foo:
> ... spam: "ham" = 1
> ...
Foo.__a
>
I'm not sure what's going on here, and it's probably not actually
enum-specific, but that's where I saw it.
If you create a plain class and have an attribute with an annotation,
you can see that:
>>> class Foo:
... spam: "ham" = 1
...
>>> Foo.__a
Foo.__abstractmethods__ Foo.__annotations__