
"Phil Bouchard" <philippe@fornux.com> wrote in message news:g292r8$12m$1@ger.gmane.org...
Hi,
Firstly after defining my own sh::pool allocator new doors opened on their own and now I am able to replace the "new_sh<>()" function call with a much more neat C++ approach with "new shifted<>()". For example instead of:
shifted_ptr<char[9]> u = new_sh<char[9]>();
Now we can write: shifted_ptr<char[9]> u = new shifted<char[9]>();
This will allows us defining STL container allocators more easily because of the distinct steps the constructor and allocator are called; new_sh<>() was mixing them altogether.
[...] Ok I just added a skeleton for a STL compliant allocator called "shifted_allocator" in "sh_owned_base_nt.hpp" of my sandbox. This is an example of how it should be written, unfortunately I wasn't able to make it compile but this is basically the final step. There are some FIXME in the header and shifted_ptr_test2.cpp file. Thanks, -Phil