syntactic sugar

"In computer science, syntactic sugar is syntax within a programming language that is designed to make things easier to read or to express. It makes the language "sweeter" for human use: things can be expressed more clearly, more concisely, or in an alternative style that some may prefer." -- https://en.wikipedia.org/wiki/Syntactic_sugar

Unravelling t-strings

PEP 750 introduced t-strings for Python 3.14. In fact, they are so new that as of Python 3.14.0b1 there still isn't any documentation yet for t-strings. 😅 As such,

MVPy: Minimum Viable Python

Over 32 posts spanning well over 2 years, this is the final post in my blog series on Python's syntactic sugar. I had set out to find all of the Python

Unravelling `del`

In my post on unravelling the global statement, I mentioned how after my PyCascades 2023 talk some people came up to me about a couple of pieces of Python syntax that I had

Unravelling `global`

While preparing my talk for PyCascades 2023 on this very blog post series of Python's syntactic sugar, I had an inkling that I could unravel the global statement. After talking to

Unravelling `lambda` expressions

When I first wrote my series on Python's syntactic sugar, I left out lambda expressions as I knew I couldn't unravel them without unravelling assignment expressions. Luckily, I solved

© 2013 Brett Cannon