evaluation question
Thomas Passin
list1 at tompassin.net
Tue Jan 31 19:11:55 EST 2023
On 1/31/2023 6:18 PM, Greg Ewing wrote:
> On 1/02/23 7:33 am, Stefan Ram wrote:
>> Thomas Passin <list1 at tompassin.net> writes:
>
>> Some people say it is a function now so that you can redefine it.
Hmm, I didn't write these quotes. Maybe someone got confused by the
depth of the nested replies in this thread. Easy enough to do.
> Well, that's one benefit, but I wouldn't say it's the main one.
>
> The point is really that you can do *anything* with it now that
> you can do with a regular function -- pass it as an argument,
> wrap it with another function, define your own function with a
> similar signature for duck-typing purposes, etc.
>
>> It would still be possible to have a special syntax for the outermost
>> expression of an expression statement that would allow one to omit
>> the parentheses,
>
> That's only one of the syntactic oddities of the old print
> statement, thogh. There was also the >> thing, special treatment
> of trailing commas, etc.
>
> Also, introducing a paren-less call syntax would be a very big
> and controversial change that would be way out of proportion to
> the problem.
>
More information about the Python-list
mailing list