www.digitalmars.com         C & C++   DMDScript  

digitalmars.D - Object Pool

Does something to manage object pooling exists (thread safe)?

Something like:

auto pool =3D new Pool!MyObj;
auto obj =3D pool.get;

...
...
...

pool.release(obj); // or maybe obj.release;

In a thread-safe way.
Jul 19 2012