[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Allocators done



I've created two new allocators, ppDynMemAlloc and ppDynObjAlloc,
ppDynObjAlloc being a derivative of ppDynMemAlloc. These two allocators
behave very much like ppStatMemAlloc and ppStatObjAlloc, except that they
don't have the requirement of the client having to specify the exact max
amount of memory that can be allocated.

This was the feature you requested. I choose to implement it in a new class,
rather than alter the old so that both possibilities would be possible to
choose whenever an allocator is used.

Only the "obj" versions of the allocators (ie, ppObjAlloc, ppStatObjAlloc
and ppDynObjAlloc) are template classes, and they all have only few and
small methods, making the template bloat as minimal as possible, while
giving real functionality in return (ie, handling exceptions thrown from
constructors in the same way as new does).

Also, I've fully documented all the 6 allocators, which are all finished and
ready to be used. The source is coming in priv. mail.

The docs are pretty detailed, so as to leave no doubt about the behavior of
these classes.

I checked out perceps. Pretty cool. Only it produced output that in some
cases was a little weird. Possibly I've made an error somewhere in the way
I've documented the classes (have been unable to find out what), or there is
a bug in either perceps or my Win32 perl enterpreter. Probably just me
screwing things up ;)