
11 Mar
2005
11 Mar
'05
10:07 p.m.
Jonathan Turkanis wrote:
struct some_filter // details ommitted { template<typename Source> character::value_type get(Source& src) { character c; if (c = boost::io::get(src)) { // c is good() }; return c; } };
I'm not sure how this works; within some_filter get, do you have to use c.value()?
No, provided you give the character class all the operators defined for char comparison, etc.
I'm going to try using char converion and a safe-bool conversion, except on Borland where the safe-bool conversion will be a plain conversion. If it doesn't work, I''ll go back to good().
Thanks for all your suggestions.
Suggestions are cheap :) Matt