4 ms·
Hence most likely. But when you are throwing around shared pointers left and right the program is usually already in the phase of "I don't know... just stick in
by zeotroph 7y ago
Hence most likely. But when you are throwing around shared pointers left and right the program is usually already in the phase of "I don't know... just stick into a shared_ptr to be safe".
- butterisgood 7y agoAnd that’s my concern too. Shared pointers aren’t free. You can solve problems with them but the moment I see them in code it raises flags that make me think someone gave up solving the actual problem at hand and “this seemed to work”. I’ve seen many an otherwise good looking code base paint itself into corners over object ownership, life cycles and resource reclamation.