[Boost-bugs] [Boost C++ Libraries] #6909: [Functional/Forward] Add tr1_result_of specialization

Subject: [Boost-bugs] [Boost C++ Libraries] #6909: [Functional/Forward] Add tr1_result_of specialization
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2012-05-17 15:00:58


#6909: [Functional/Forward] Add tr1_result_of specialization
-------------------------------------+--------------------------------------
 Reporter: michel | Owner: t_schwinger
     Type: Bugs | Status: new
Milestone: To Be Determined | Component: functional/forward
  Version: Boost Development Trunk | Severity: Problem
 Keywords: |
-------------------------------------+--------------------------------------
 To make `result_of` and `tr1_result_of` equivalent, we have to add
 specialization of `tr1_result_of`.
 (Boost.!Functional/Forward already has specialization of `result_of`.)

 Also, it would be nice to avoid specialization of `result_of`, when we use
 decltype-based `result_of`.
 (As for `tr1_result_of`, it should be specialized even when decltype-based
 `result_of` is used.)

 So, instead of
 {{{
 template <...>
 struct result_of<F()>
 {
     typedef XXXX type;
 };
 }}}
 we should write
 {{{
 #if !defined(BOOST_RESULT_OF_USE_DECLTYPE) || defined(BOOST_NO_DECLTYPE)
 template <...>
 struct result_of<F()>
 {
     typedef XXXX type;
 };
 #endif

 template <...>
 struct tr1_result_of<F()>
 {
     typedef XXXX type;
 };
 }}}

 A quick grep said the following files specialize `result_of`.
 * functional/forward_adapter.hpp
 * functional/lightweight_forward_adapter.hpp

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/6909>
Boost C++ Libraries <http://www.boost.org/>
Boost provides free peer-reviewed portable C++ source libraries.

This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:09 UTC