1.. Copyright David Abrahams 2004. Use, modification and distribution is 2.. subject to the Boost Software License, Version 1.0. (See accompanying 3.. file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 4 5:: 6 7 template <class Dereferenceable> 8 struct pointee 9 { 10 typedef /* see below */ type; 11 }; 12 13:Requires: For an object ``x`` of type ``Dereferenceable``, ``*x`` 14 is well-formed. If ``++x`` is ill-formed it shall neither be 15 ambiguous nor shall it violate access control, and 16 ``Dereferenceable::element_type`` shall be an accessible type. 17 Otherwise ``iterator_traits<Dereferenceable>::value_type`` shall 18 be well formed. [Note: These requirements need not apply to 19 explicit or partial specializations of ``pointee``] 20 21``type`` is determined according to the following algorithm, where 22``x`` is an object of type ``Dereferenceable``:: 23 24 if ( ++x is ill-formed ) 25 { 26 return ``Dereferenceable::element_type`` 27 } 28 else if (``*x`` is a mutable reference to 29 std::iterator_traits<Dereferenceable>::value_type) 30 { 31 return iterator_traits<Dereferenceable>::value_type 32 } 33 else 34 { 35 return iterator_traits<Dereferenceable>::value_type const 36 } 37 38