4 ms·
Interesting, from that slide I should always null my variables after I'm finished with them.
by doublerabbit 6y ago
Interesting, from that slide I should always null my variables after I'm finished with them.
- sfink 6y agoIf they're globals, then yes you should. Having dangling pointers anywhere, even in supposedly unused areas, tends to come back and bite you. For locals, why bother? The optimizer will probably discard the writes, and worrying about stack addresses being reused is a waste of mental space and clutters the code.