
13 Apr
2012
13 Apr
'12
4:15 a.m.
2012/4/12 Nathan Ridge <zeratul976@hotmail.com>:
There is one more solution: determinate stream_char<>::type for UserType using lots of meta-programming. For that solution following meta-functions required: has_output_stream_operator_for_char<UserType>::value has_output_stream_operator_for_wchar_t<UserType>::value has_output_stream_operator_for_char16_t<UserType>::value has_output_stream_operator_for_char32_t<UserType>::value
Is there any ideas, how that can be done in a *portable* way?
Perhaps Boost.TTI can be of help?
Boost.TypeTraits looks like a good solution. Using has_left_shift<> and has_right_shift<> it is possible to create required meta-functions. Created ticket #6786 -- Best regards, Antony Polukhin