Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Related Rants
Assert ref != NULL rather than conditional check it more often.
Silently returning / ignoring is way worse if object was meant to be valid.
The caller should deal with it. (As abstract as possible preferably...)
Obviously there's places where conditional is necessary.. but silent null checks can cause more pain than good.
undefined
code design
assert
null