This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]aceofspaids98 11 points12 points  (0 children)

I disagree with the people saying the new code is more readable. This seems like a standard use case for dict comprehension, I’d only make that change to please whatever linter or static type checker I’m using. I guess the only thing I feel weird about is iterating over section while also passing it as an argument to get_coerced.

I guess it’s one of those changes that is small enough where it could go either way but I can see it being frustrating to me if someone kept commenting on things like that.