On Wed, Jul 25, 2018 at 07:06:35PM -0400, David Mertz wrote:

> And yes, the problem is that the equivalent is actually:
> 
>     v = a
>     if v is not None: v=a.b
> 
> The semantics are simply not the ones that are intuitive to most people
> reading 'v = a?.b'

Tell us more about these "intuitive to most people" semantics. What are 
they? Did you do a survey? How many people did you ask?

Did you do a comparison to the "intuitive to most people" semantics of 
slicing syntax?

Intuitive does not mean "familiar".

If you're going to dismiss a proposal because it's not "intuitive"[1] 
then to avoid accusations of intellectual hypocracy you need to do one 
of two things:

- demonstrate that the syntactic features we know and love and use 
  frequently (e.g. slicing, decorators, comprehensions) are intuitively
  obvious and don't need to be learned;

- or say that *those features were terrible errors* that Python still
  has not recovered from.


You can't have it both ways: its okay that people have to learn slicing, 
decorators, comprehensions, never mind that they aren't intuitive, for 
*those* features "intuitiveness" isn't that important; but for this 
proposal, "intuitiveness" is all the matters: usefulness, conciseness 
and the increase in expressivity don't matter one whit.

Its one thing to say that slicing, dot attribute access, decorators, 
augmented assignment, comprehensions etc are mistakes we should not 
repeat. But this double-standard of demanding higher standards for new 
features than we accept in existing, beloved features is one that we 
should reject with extreme prejudice.





[1] To whom? Babies? First-time programmers? People with a Ph.D. in comp 
sci and thirty years experience in half a dozen languages?


-- 
Steve
_______________________________________________
Python-ideas mailing list
Python-ideas@python.org
https://mail.python.org/mailman/listinfo/python-ideas
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to