// This is a silly example, but it demonstrates that the type of a lazy default // probably should not be evaluated when the parameter is given explicitly // (since the type of the default is never needed in that case). #include BOOST_PARAMETER_NAME(param); template struct empty {}; struct my_default_computer { #if 0 // What I need to do now (broken): typedef empty::type result_type; #else // What I want to do: template struct result {typedef typename empty::type type;}; #endif }; int main(int, char**) { (_param = 0)[_param || my_default_computer()]; return 0; }