pointee and indirect reference
David Abrahams · 2004
abstract: Provides the capability to deduce the referent types of pointers, smart pointers and iterators in generic code. Overview Have you ever wanted to write a generic function that can operate on any kind of dereferenceable object? If you have, you’ve probably run into the problem of how to determine the type that the object “points at”: template void f(Dereferenceable p) what-goes-here? value = *p; pointee It turns out to be impossible to come up with a fully-general algorithm to do determine what-goes-here directly, but it is possible to require that pointee ::type is correct. Naturally, pointee has the same difficulty: it can’t determine the appropriate::type reliably for all Dereferenceables, but it makes very good guesses (it works for all pointers, standard and boost smart pointers, and iterators), and when it guesses wrongly, it can be specialized as neccessary: namespace boost
Cited by 0 works.