Re: [GD-General] Compile times
Brought to you by:
vexxed72
From: Jesse J. <jes...@mi...> - 2002-12-17 11:41:43
|
At 5:58 PM +0100 12/16/02, Ignacio Casta=F1o wrote: >Jesse Jones wrote: >> I have some thoughts on how this can be done, but I'd like to hear >> some more details on how you've implemented this. :-) > >Well, that was mentioned some time ago in the Algorithm mailing list by Tom >Forsyth, I think... However, I saw that for the first time in the fmod soun= d >library to handle channel references. Thanks for the summary. How is this better than simply ref counting objects though? >I don't think that handles are the solution to all the problems and that >smart pointers are bad. However, I think that there are many ways of using >smart pointers wrong, while the handle method is simple and errors are easy >to catch. Well, this is a separate issue: you don't have to use a smart pointer if you ref count your objects. It just makes the code clearer and eliminates a source of errors since the ref counting is automated. Having said the smart pointers are normally very simple. As a rule they don't use any template meta-programming wackiness and they contain very little code (look at the boost smart pointer implementations for example). It's hard to go wrong if you have a solid understanding of how constructors and assignment operators work. -- Jesse |