4 ms·
How often do you care about the order in which objects are dropped?
by whyever 1y ago
How often do you care about the order in which objects are dropped?
- throwawaymaths 1y agoanything where you need to have stuff run in constant time.
- mikepurvis 1y agoIf you're in hard realtime land then you can't have any allocations at all; that's a pretty different ballgame. Destructors should be as simple and side-effect free as possible, with the exception of things like locks or file handles where the expectation is very clear that the object going out of scope will trigger a release action.