Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Namespace Members | Class Members

s11n::object_deleter Struct Reference

Deletes an object passed to it. More...

#include <functor.h>

List of all members.

Public Member Functions

template<typename T> void operator() (const T *t) const
 Deletes t.

template<typename T> void operator() (const T &t) const
 Does nothing: is here to allow some reference-vs-pointer-type transparency.


Detailed Description

Deletes an object passed to it.

This type accepts non-pointer types for "destruction." This is a non-operation, and is supported to allow other template code to generically free objects without needing to know if they are pointers. This allows some formerly-non-consolidatable reference-vs-pointer-type code to share a single implementation, as "delete(myobj)" is not valid for non-pointer types, but object_deleter()(myobj) is.

Definition at line 36 of file functor.h.


The documentation for this struct was generated from the following file:
Generated on Wed Jul 28 16:04:15 2004 for s11n by doxygen 1.3.7