Re: Why does super(bool) give None

2020-04-24 Thread Chris Angelico
On Sat, Apr 25, 2020 at 4:20 AM Random832 wrote: > > On Fri, Apr 24, 2020, at 02:10, Cecil Westerhof wrote: > > issubclass(bool, int) gives True > > but > > super(bool) gives > > > > Do I not understand the meaning of super, or is this inconsistent? > > I've never heard of a one-argument form for

Re: Why does super(bool) give None

2020-04-24 Thread Random832
On Fri, Apr 24, 2020, at 02:10, Cecil Westerhof wrote: > issubclass(bool, int) gives True > but > super(bool) gives > > Do I not understand the meaning of super, or is this inconsistent? I've never heard of a one-argument form for super, but I just tried something and now I'm confused about the

Re: Why does super(bool) give None

2020-04-24 Thread Cecil Westerhof
Cecil Westerhof writes: >> I've never actually looked at the repr of a super object - I've always >> just called a method on it immediately after constructing it. Never >> seen a need to hang onto one :) > > Well, maybe I will never need it, but I am just curious. And sometimes > it was very hand

Re: Why does super(bool) give None

2020-04-24 Thread Cecil Westerhof
Chris Angelico writes: > On Fri, Apr 24, 2020 at 4:16 PM Cecil Westerhof wrote: >> >> issubclass(bool, int) gives True >> but >> super(bool) gives >> >> Do I not understand the meaning of super, or is this inconsistent? >> >> (Until now I have not down much work with classes in Python.) >> > >

Re: Why does super(bool) give None

2020-04-23 Thread Chris Angelico
On Fri, Apr 24, 2020 at 4:16 PM Cecil Westerhof wrote: > > issubclass(bool, int) gives True > but > super(bool) gives > > Do I not understand the meaning of super, or is this inconsistent? > > (Until now I have not down much work with classes in Python.) > One-arg super is an unbound object, and

Why does super(bool) give None

2020-04-23 Thread Cecil Westerhof
issubclass(bool, int) gives True but super(bool) gives Do I not understand the meaning of super, or is this inconsistent? (Until now I have not down much work with classes in Python.) -- Cecil Westerhof Senior Software Engineer LinkedIn: http://www.linkedin.com/in/cecilwesterhof -- https://ma