Postscript: Things are not as clean as I have hoped and said. However, I
don't think this changes the general form of the conclusion. Just that a
little more work is needed to achieve the goal.

Python 3.7 and 3.8:
    >>> def f(x): pass
    >>> f()
    TypeError: f() missing 1 required positional argument: 'x'

Also note that in Python 3.8 we have:
    >>> def f(x,/): pass
    >>> f()
    TypeError: f() missing 1 required positional argument: 'x'

Recall that we have
    >>> len()
    TypeError: len() takes exactly one argument (0 given)

Note that the parameter of 'f' has a name, but not the parameter for 'len'.
I think I was expecting
    >>> def f(x,/): pass
    >>> f()
    TypeError: f() takes exactly one argument (0 given)

-- 
Jonathan
_______________________________________________
Python-ideas mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3/lists/python-ideas.python.org/
Message archived at 
https://mail.python.org/archives/list/[email protected]/message/5BKOPHXXG6JYFBNPA2VWFZEVO5YFBOFV/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to