|
Boost : |
Subject: Re: [boost] review request: addition to type_traits library of is_less_comparable<T, U> and others
From: Frédéric Bron (frederic.bron_at_[hidden])
Date: 2009-10-11 01:28:19
> It may be that being able to examine the return type -- we never did anything to make that work, did we? -- of the various operators would leave the answer to that question to the caller. Â For example, if < returns void, but > returns something convertible to bool, generic code could use > instead of < for sorting. Â (Far fetched, to be sure, but the idea, in general, seems reasonable.)
We had a bit of discussion before that thread and never achieved to
get the exact result type of an operator. The only thing we could do
is know if the result type is convertible to something.
If somebody has a code to get the result type of some function, it
would be very interesting to add that traits alone...
Frédéric
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk