id summary reporter owner description type status milestone component version severity resolution keywords cc 339 Tribool: strange results on I/O ethouris327 Douglas Gregor "{{{ Please look at the code below: #include #include using namespace std; using namespace boost::logic; #define PRINTEXP( exp ) print_exp( #exp, exp ) inline void print_exp( const char* name, tribool expr ) { cout << name << "": "" << boolalpha << expr << endl; } int main( int argc, char** argv ) { cout << true << endl; cout << false << endl; cout << indeterminate << endl; const tribool yes = true; const tribool no = false; const tribool maybe = indeterminate; PRINTEXP( yes ); PRINTEXP( no ); PRINTEXP( maybe ); return 0; } According to the documentation, the result should be: 1 0 2 yes: true no: false maybe: indeterminate However the result is: 1 0 1 yes: true no: false maybe: false Of course, there is a warning when compiling: lite-3bool.cc:20: warning: the address of `bool boost::logic::indeterminate(boost::logic::tribool, boost::logic::detail::indeterminate_t)', will always be `true' which excuses the ""1"" for indeterminate, however also proves that no `ostream& << tribool' is defined (or it's somehow not seen). > uname -a CYGWIN_NT-5.1 hostname 1.5.12(0.116/4/2) 2004-11- 10 08:34 i686 unknown unknown Cygwin > g++ -v ... Thread model: posix gcc version 3.3.3 (cygwin special) }}}" Bugs closed None None Fixed