18 Aug
2013
18 Aug
'13
2:43 p.m.
On 18/08/13 08:30, TONGARI J wrote:
Hi folks,
It's over 2 years since this post: http://boost.2283326.n4.nabble.com/New-powerful-way-to-use-enable-if-in-C-0x...
The macro looks sweet and I wonder if we have this macro in Boost in case that I missed it.
What's the practical reason of having a macro? The approaches suggested in the thread all have limitations. For example they require you to put some unique non-ambiguous type in all your overloads of a said function. The classical approach recommended for enable_if is still the best way to use SFINAE for a boolean meta-function or a boolean constant expression. For this one, you're better off just knowing what you're doing than to rely on macro magic.