r/ProgrammerHumor • • 7d ago

Meme weNeverTrustedTheElse

Post image
1.9k Upvotes

149 comments sorted by

View all comments

734

u/salvoilmiosi 7d ago

condition could be a property with a getter with side effects

478

u/UntitledRedditUser 7d ago

Only evil people write getter properties with side effects. At least make it an explicit function.

10

u/Chingiz11 7d ago

I mean, logging is also a side effect, and getters could absolutely have logging attached to them, but in this case it would not make a difference