In August 2020, in the context of PEP 472 I suggested
    >>> {-}
for the empty set literal. At present the closest we can do for an empty
set literal is
    >>> {0} - {0}
    set()

The context for this is whether PEP 472 should make
    >>> something[]
a syntax error. If we do then, what about the workarounds
    >>> something[*argv]
    >>> something[**kwargs]
which so to speak convert the syntax error to a run-time error.

Because
    >>> something[]
was ugly and easily misunderstood I suggested
    >>> something[-]
and hence
    >>> {-}
as new syntax.

The thread from August 2020 can be found (with >>> prompts as quotes) at
https://mail.python.org/archives/list/python-ideas@python.org/thread/2QANGFBMGUSCYOLU3GJ6AOGV6Q2ATC72/#QOBONXUPUMC3ULCGJU6FVHOCIZQDT45W

-- 
Jonathan
_______________________________________________
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/TEZUX6EMOLZBMN6GYJC5J5J5KR2QGTOT/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to