Is there a way to determine the open mode for an open stream? In Sun Workshop 5.0 I used Stream.rdbuf()->which_open_mode(). Thanks (I am using gcc version 2.95.2 on Solaris 2.6)