Re:No-op statements syntactically valid only since Python X.Y
by carapace on Tuesday June 07, 2022 @12:59PM
(#31657175)
> Conversely, it gets easier to write outside tools that interact with Python code by removing corner cases and simplifying the grammar.
That sounds like a false economy to me. A one time small savings of developer effort (implementing the old grammar rule for decorators wasn't onerous?) to permit foolish and unnecessary intricacies among the laity.
> It means people are likely to trip over it.
Only if they are attempting to do something foolish. (Who puts whole expressions in a decorator!?)
- - - -
Tell you what, you go find examples where people have tripped over it in the past and I'll code golf them to see if I can come up with something idiomatic and simpler. Does that sound like fun to you? ("Cause it does to me. Candy!)
That sounds like a false economy to me. A one time small savings of developer effort (implementing the old grammar rule for decorators wasn't onerous?) to permit foolish and unnecessary intricacies among the laity.
> It means people are likely to trip over it.
Only if they are attempting to do something foolish. (Who puts whole expressions in a decorator!?)
- - - -
Tell you what, you go find examples where people have tripped over it in the past and I'll code golf them to see if I can come up with something idiomatic and simpler. Does that sound like fun to you? ("Cause it does to me. Candy!)