Re: Typing on child class' methods of a Generic base class

2022-03-12 Thread Dieter Maurer
Nicolas Haller wrote at 2022-3-12 12:05 -0500: >On 2022-03-10 12:31, Dieter Maurer wrote: >> Nicolas Haller wrote at 2022-3-9 10:53 -0500: >>> ... >>> The documentation about "user-defined generic types"[1] says that I can >>> fix some types on a child class (class MyDict(Mapping[str, T]):) but >>>

Re: Typing on child class' methods of a Generic base class

2022-03-12 Thread Nicolas Haller
On 2022-03-10 12:31, Dieter Maurer wrote: Nicolas Haller wrote at 2022-3-9 10:53 -0500: ... The documentation about "user-defined generic types"[1] says that I can fix some types on a child class (class MyDict(Mapping[str, T]):) but doesn't say much about the signature of the methods I need to i

Re: Typing on child class' methods of a Generic base class

2022-03-10 Thread Dieter Maurer
Nicolas Haller wrote at 2022-3-9 10:53 -0500: > ... >The documentation about "user-defined generic types"[1] says that I can >fix some types on a child class (class MyDict(Mapping[str, T]):) but >doesn't say much about the signature of the methods I need to >implement/override on that child class.

Typing on child class' methods of a Generic base class

2022-03-09 Thread Nicolas Haller
Hello, I am wondering about a situation involving typing, Generic and a child class. The documentation about "user-defined generic types"[1] says that I can fix some types on a child class (class MyDict(Mapping[str, T]):) but doesn't say much about the signature of the methods I need to imp