[#BloombergLP-bslma-DeleterHelper-deleteObjectRaw] = xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bslma.adoc[bslma]::xref:BloombergLP/bslma/DeleterHelper.adoc[DeleterHelper]::deleteObjectRaw :relfileprefix: ../../../ :mrdocs: Destroy `object` and deallocate its memory footprint. == Synopsis Declared in `<bslma_deleterhelper.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- template< class TYPE, class ALLOCATOR> static void deleteObjectRaw( TYPE const* object, ALLOCATOR* allocator); ---- == Description Destroy the specified `object` and then use the specified `allocator` to deallocate its memory footprint. Do nothing if `object` is a null pointer. The behavior is undefined unless `allocator` is non‐null, `object` is *not* a secondary base class pointer (i.e., the address is (numerically) the same as when it was originally dispensed by `allocator`), and `object` was allocated using `allocator` and has not already been deallocated. == Parameters [cols="1,4"] |=== | Name| Description | *object* | object to destroy and whose memory to deallocate | *allocator* | allocator (or pool) that supplied `object`'s memory |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#