On 6/5/10 6:01 AM, alfC wrote:
On Jun 3, 7:52 pm, Joel de Guzman
wrote: On 6/4/10 10:31 AM, alfC wrote: There is hope. Just specialize boost::phoenix::result_of_xxx (e.g. boost::phoenix::result_of_plus
). I specilized result_of_multiplies and still no luck: #include
#include<iostream> #include<typeinfo> #include namespace boost{ namespace phoenix{ using namespace boost::units; template<> //in general template
struct result_of_multiplies si::length, quantitysi::length { typedef quantitysi::area type; }; }}
The type-deduction respects references. Phoenix2 passes in references.
The code should be:
template<> //in general template