Reply 60 of 61, by keenmaster486
- Rank
- l33t
Who does that? In the second version you could also just do (obj != null && obj.SomeMember == null) anyway.
World's foremost 486 enjoyer.
Who does that? In the second version you could also just do (obj != null && obj.SomeMember == null) anyway.
World's foremost 486 enjoyer.
keenmaster486 wrote on 2026-11-20, 19:54:Who does that?
Someone at my workplace. Some methods were lacking null check after another call returning that obj. Apparently it was stylistic choice just because some other similar methods had this check added (but didn't need to have check for something inside obj at that point).
The guy just said there's nothing really wrong with that. How is adding redundant code OK? The same guy claimed at some point there's nothing wrong with losing performance because modern CPUs make up for it.
There should be a law against these people writing code.
The old app written by another person before most old devs left was much faster, although still slow. 20 seconds to get in on old low-end and smartphone from 12 years ago. New one takes over a minute.
But of course it's not apparent on new phones. How much horsepower is wasted on hiding inefficiencies...
wrote:A man can be himself only so long as he is alone; and if he does not love solitude, he will not love freedom; for it is only when he is alone that he is really free.