[Anthony Williams] > On Windows, for example, you can use GlobalAlloc to allocate some memory, and > you get an HGLOBAL back --- a handle to the memory. You need to call > GlobalLock with that handle to get a pointer to the memory which you can > actually use. The resource manager therefore needs to keep track of the > handle, rather than the pointer (which may be different after different calls > to GlobalLock, if there has been an intervening GlobalUnlock). Indeed, the > pointer to the locked memory is essentially a separate resource, acquired with > GlobalLock() and released with GlobalUnlock. It would be sensible to be able > to use the same framework for both the handle and the pointer.
This sounds like a perfect case where using a smart_PTR would be very confusing, maybe dangerously so! Err.. but just to be sure, are you saying this in support of smart_resource? Regards, [)o IhIL.. _______________________________________________ Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost