Terry Reedy wrote:
Boris Borcic wrote:
...
- allowing containment tests, ie x in Number to invoke isinstance()
in the background when the container is of type type. My brain is
too muddled by flu at the moment, to see whether Guido's fabled time
machine allowed him to already provide all
Bruno Desthuilliers wrote:
[EMAIL PROTECTED] a écrit :
...
A intriguing wider proposition would be to transpose Ruby's notion of
Open Classes to Python built-in metaclasses (or just to type
itself ?).
No, thanks. Even the Ruby guys start to think making evrything open may
not be such a good
Bruno Desthuilliers wrote:
Boris Borcic a écrit :
Given the ABC innovation, maybe an infix syntax for isinstance() would
be good.
Possibilities :
- stealing is away from object identity. As a motivation, true use
cases for testing object identity are rare;
x is None is a *very* common
Boris Borcic a écrit :
Bruno Desthuilliers wrote:
Boris Borcic a écrit :
Given the ABC innovation, maybe an infix syntax for isinstance() would
be good.
Possibilities :
- stealing is away from object identity. As a motivation, true use
cases for testing object identity are rare;
x is None
[EMAIL PROTECTED] a écrit :
Bruno Desthuilliers dixit :
Boris Borcic a écrit :
Given the ABC innovation, maybe an infix syntax for isinstance() would
be good.
Possibilities :
- stealing is away from object identity. As a motivation, true use
cases for testing object identity are rare;
x is
Bruno Desthuilliers dixit :
Boris Borcic a écrit :
Given the ABC innovation, maybe an infix syntax for isinstance() would
be good.
Possibilities :
- stealing is away from object identity. As a motivation, true use
cases for testing object identity are rare;
x is None is a *very*
Given the ABC innovation, maybe an infix syntax for isinstance() would be good.
Possibilities :
- stealing is away from object identity. As a motivation, true use cases for
testing object identity are rare; forcing the usage of a function or method to
test it, would dissuade abuse.
-
Boris Borcic:
- combining both keywords to create a third one, eg is in
A note only on syntax: isa seems better for Python. I don't comment
how useful it can be.
Bye,
bearophile
--
http://mail.python.org/mailman/listinfo/python-list
Boris Borcic a écrit :
Given the ABC innovation, maybe an infix syntax for isinstance() would
be good.
Possibilities :
- stealing is away from object identity. As a motivation, true use
cases for testing object identity are rare;
x is None is a *very* common test. Using a _marker object
Boris Borcic wrote:
Given the ABC innovation, maybe an infix syntax for isinstance() would
be good.
Possibilities :
- stealing is away from object identity. As a motivation, true use
cases for testing object identity are rare; forcing the usage of a
function or method to test it, would
10 matches
Mail list logo