Will Python add `{:}`, `{,}` and maybe `(,)` in or before 3.15 (October 2026)?
Basic
7
Ṁ129
2026
27%
chance

See https://discuss.python.org/t/add-the-ability-to-declare-an-empty-dict-as/25213/19

I made a proposal with a modified grammar some years ago that would make {,} the empty set. If there was a real desire for this, a similar change could be made so that both {,} == set() and {:} == dict() such that {} could, eventually over a very long time, be removed.

One thing that actually changing the grammar unveiled was that once {,} becomes a legal literal, it becomes extremely easy to make (,) legal, which IMO is another wart on the language (parentheses don’t make tuples, commas do; oh, except for an empty tuple, then you must always use parentheses and no comma).

Get
Ṁ1,000
and
S3.00
© Manifold Markets, Inc.Terms + Mana-only TermsPrivacyRules