From: Ian Chapman Newsgroups: comp.os.msdos.djgpp Subject: PEST or BUG Date: Wed, 19 Nov 1997 07:29:41 -0500 Organization: Nortel Message-ID: <3472DBB5.71A7@nortel.ca> Reply-To: ichapman AT nortel DOT ca NNTP-Posting-Host: bcarib90.bnr.ca Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Lines: 27 To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Precedence: bulk // To test the cout under conditions of varying format. #include int main() { int Ia, Ib; float Fc; Ia = 0x1a; Ib = 0x1b; Fc = 123.56789; cout << "Ia in dec is ..." << Ia << endl; // prints in decimal cout << "Ib in dec is ..." << Ib << endl; // prints in decimal cout << "Ia in hex is ..." << hex << Ia << endl; // prints in HEX cout << "Ib in dec is ..." << Ib << endl; // still prints in HEX cout << "Ia in dec is ..." << Ia << endl; cout << "Ib in dec is ..." << Ib << endl; cout << "Fc is float ..." << Fc << endl; // Okay cout << "Ia in dec is ..." << Ia << endl; // still prints in HEX cout << "Ib in dec is ..." << Ib << endl; } Hi all, this is a pest and I can live with it. My preference is to have cout in dec at every call and only stream through hex when explicitly called. As some one who is involved in applications close to the hardware I need hex. I must wonder what this will do to many of the libs and class libs. Regards Ian.