id summary reporter owner description type status milestone component version severity resolution keywords cc 9953 lazy_enable_if is not sfinae friendly hui.li@… Peter Dimov "The following code fails to compile, even though boost::result_of itself is sfinae friendly. {{{ template < typename T > typename boost::lazy_enable_if_c< boost::is_class::value, boost::result_of >::type test(int){} template < typename > void test(...) {} struct A{}; // boost::result_of is a valid type that doesn't have a member called ""type"" int main(int argc, const char * argv[]) { test(0); // test(int) meant to be a substitution failure return 0; } }}} I'm not sure if this is a bug/flaw, or a lack of feature, or maybe this kind of use is deliberately disallowed for some reason, but it could be very useful if {{{lazy_enable_if_c}}} etc support uses when {{{typename T::type}}} itself may cause a substitution failure. Proposing to change implementation of {{{lazy_enable_if_c}}} and {{{lazy_disable_if_c}}} to: {{{ template struct lazy_enable_if_c : T {}; // inherits from T template struct lazy_enable_if_c {}; template struct disable_if_c : T {}; // inherits from T template struct disable_if_c {}; }}} " Feature Requests new To Be Determined core Boost 1.55.0 Problem