From 0dd5dae4e8d607328ded5973526b1b13fd844e59 Mon Sep 17 00:00:00 2001 From: Ronald Garcia Date: Tue, 22 Jul 2008 14:55:05 +0000 Subject: [PATCH] Added documentation for unwrap_ref. [SVN r47689] --- doc/ref.xml | 30 ++++++++++++++++++++++++++---- 1 file changed, 26 insertions(+), 4 deletions(-) diff --git a/doc/ref.xml b/doc/ref.xml index 39fede9..c64f316 100644 --- a/doc/ref.xml +++ b/doc/ref.xml @@ -59,10 +59,13 @@ references to function templates (algorithms) that would usually take copies of their arguments. It defines the class template boost::reference_wrapper<T>, - the two functions + two functions boost::ref and boost::cref that return - instances of boost::reference_wrapper<T>, and the + instances of boost::reference_wrapper<T>, + a function boost::unwrap_ref + that unwraps a boost::reference_wrapper<T> or + returns a reference to any other type of object, and the two traits classes boost::is_reference_wrapper<T> and @@ -90,6 +93,11 @@ boost::cref(x) returns a boost::reference_wrapper<X const>(x). + The expression boost::unwrap_ref(x) + returns a + boost::unwrap_reference<X>::type& where X + is the type of x. + The expression boost::is_reference_wrapper<T>::value is true if T is a reference_wrapper, and @@ -180,6 +188,19 @@ Does not throw. + + + + unwrap_reference<T>::type& + + T& + + + unwrap_reference<T>::type&(t) + + Does not throw. + + @@ -234,7 +255,8 @@ Peter Dimov because they are generally useful. Douglas Gregor and Dave Abrahams contributed is_reference_wrapper and - unwrap_reference. + unwrap_reference. Frank Mori Hess and Ronald + Garcia contributed boost::unwrap_ref - \ No newline at end of file +