by pansa2 · 1y ago · 0 comments
Python’s grammar works great for expressions-inside-statements (and expressions-inside-expressions), but it can’t do statements-inside-expressions. Every attempt to support the latter turns out really ugly, at least in corner cases.
That said, I totally agree that full anonymous functions would be useful (especially for more complex logic). Might explore adding those later, but I love the message the current model sends.