On Wed, Dec 1, 2021 at 10:12 AM Chris Angelico <ros...@gmail.com> wrote:
> On Thu, Dec 2, 2021 at 12:42 AM David Mertz, Ph.D. > <david.me...@gmail.com> wrote: > >> 4) If "no" to question 1, is there some other spelling or other small > >> change that WOULD mean you would use it? (Some examples in the PEP.) > > > > Yes, the delay/later/defer keyword approach is not confusing, and does > not preempt a later feature that would actually be worth having. > > Do you mean changing the spelling of the existing proposal, or a > completely different proposal for deferred objects that are actually > objects? Because that is NOT what I mean by a "small change". :) > The spelling of the existing proposal. I.e. if the proposal were: def fun(things: list[int] = defer []) -> int: # ... some implementation I'd be -0 on the idea rather than -100. Yes, my change in attitude is largely because I want *some future PEP* to address the more general situation like: result = defer really_expensive_calculation() if predicate: doubled = result * 2 But I do not think your PEP does (nor even should) include that potential future behavior/syntax. Such a hypothetical future PEP would have a continuity with the syntax of your feature, albeit DEFINITELY need to address many independent concerns/issues that yours does not create. However, even if I assume the mythical future PEP never happens, in terms of readability, a WORD is vastly less confusing than a combination of punctuation that has no obvious or natural interpretation like '=>'. Or rather, I think that spelling is kinda-sorta obvious for the lambda meaning, and the use you want is kinda-sorta similar to a lambda. So I *do* understand how you get there... but it still seems like much too much line noise for a very minimal need. -- Keeping medicines from the bloodstreams of the sick; food from the bellies of the hungry; books from the hands of the uneducated; technology from the underdeveloped; and putting advocates of freedom in prisons. Intellectual property is to the 21st century what the slave trade was to the 16th.
_______________________________________________ Python-ideas mailing list -- python-ideas@python.org To unsubscribe send an email to python-ideas-le...@python.org https://mail.python.org/mailman3/lists/python-ideas.python.org/ Message archived at https://mail.python.org/archives/list/python-ideas@python.org/message/ZYUOCVKLDOGJZ5H37IUOZR5MZKTBRUFM/ Code of Conduct: http://python.org/psf/codeofconduct/