
3 Oct
2008
3 Oct
'08
8:03 p.m.
on Fri Oct 03 2008, Neal Becker <ndbecker2-AT-gmail.com> wrote:
I could use one to enable a range constructor only where appropriate:
class X { template<typename range_t> X (range_t const&, enable_if<is_range<range_t> >::type *dummy=0)
Question is, what might 'is_range' look like?
I don't think it's really possible to detect it accurately. You can find out if range_begin() is overloaded in range_t's namespace, but when that is namespace boost it's not very useful information because of the default implementations. Maybe we should sink those into a subnamespace and then pull them out with a using declaration. -- Dave Abrahams BoostPro Computing http://www.boostpro.com