[#BloombergLP-bslma-DeleterHelper-deleteObject] = xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bslma.adoc[bslma]::xref:BloombergLP/bslma/DeleterHelper.adoc[DeleterHelper]::deleteObject :relfileprefix: ../../../ :mrdocs: Destroy the specified `object` based on its dynamic type 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, and `object`, when cast appropriately to `void *`, was allocated using `allocator` and has not already been deallocated. Note that `dynamic_cast<void *>(object)` is applied if `TYPE` is polymorphic, and `static_cast<void *>(object)` is applied otherwise. == Synopsis Declared in `<bslma_deleterhelper.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- template< class TYPE, class ALLOCATOR> static void deleteObject( TYPE const* object, ALLOCATOR* allocator); ---- [.small]#Created with https://www.mrdocs.com[MrDocs]#