Now the "not read-only" part:
Foo.my_prop = "whatever"
Foo.my_prop
'whatever'
You now have a string attribute, the property is lost. Methods behave the
same way and it's generally not a problem, but you should at least be aware
of this behaviour.
Yes, now I understand you. Thank you
Regard
Thomas Güttler wrote:
>
>
> Am 20.04.2017 um 14:26 schrieb Steven D'Aprano:
>> On Thu, Apr 20, 2017 at 10:39:57AM +0200, Thomas Güttler wrote:
>>
- its hard to get classproperty to work right.
>>>
>>> What is "righ"?
>>>
>>> In my case a read-only classproperty is enough. Inheritance should
Am 20.04.2017 um 14:26 schrieb Steven D'Aprano:
On Thu, Apr 20, 2017 at 10:39:57AM +0200, Thomas Güttler wrote:
- its hard to get classproperty to work right.
What is "righ"?
In my case a read-only classproperty is enough. Inheritance should be
supported.
I don't have a usecase for a sett
On Thu, Apr 20, 2017 at 10:39:57AM +0200, Thomas Güttler wrote:
> >- its hard to get classproperty to work right.
>
> What is "righ"?
>
> In my case a read-only classproperty is enough. Inheritance should be
> supported.
>
> I don't have a usecase for a setter.
The standard library is not jus
Am 19.04.2017 um 11:16 schrieb Steven D'Aprano:
On Wed, Apr 19, 2017 at 09:28:26AM +0200, Thomas Güttler wrote:
[code for a classproperty]
Nice, if it is that simple.
Is there a reason why this is not in the standard library?
I haven't had a chance to test Peter's classproperty code yet,