3 ms·
It's usually lack of garbage collection that gets to me the fastest. Closures are a close second, but those you can easily fake in nearly any language. In Ja
by dfranke 19y ago
It's usually lack of garbage collection that gets to me the fastest. Closures are a close second, but those you can easily fake in nearly any language. In Java, anonymous classes usually do the job. In C with GNU extensions, you can use nested functions as callbacks, with the caveat that they'll only be available within the dynamic scope of the caller.
- jey 19y agohttp://www.boost.org/libs/smart_ptr/shared_ptr.htm http://www.boost.org/libs/smart_ptr/shared_ptr.htm Granted, it's not garbage collection, but sometimes you have to write C++ and boost makes that manageable. boost::shared_ptr is based on refcounts, so you need to be aware of cycles and use boost::weak_ptr accordingly.
- damien 19y agoLack of garbage collection built into the language, you mean? I'm not disagreeing with you, just clarifying.
- dfranke 19y agoYes.