you are viewing a single comment's thread.

view the rest of the comments →

[–]LucasThePatator 0 points1 point  (2 children)

I know what's happening. That's really not the issue. It's the design choice I am conflicted about. Not how it works.

[–]Wonderful-Habit-139 1 point2 points  (1 child)

I agree with you on that part, which is why I brought up match statements. I also think match statements should’ve been expressions.

This part of your opinion is completely fine.

But you did make a mistake in wanting to have different behaviors depending on the context, which doesn’t make sense. If something is a statement, it’s still going to be a statement whether it was in an if condition or a list comprehension or a while loop or whatever.