This is the mail archive of the libstdc++@gcc.gnu.org mailing list for the libstdc++ project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

cin not working


Apologies if this is a known problem.

When I run the following code

#include <iostream>

using namespace std;

int main()
{
	int i;
	cin >> i;
	cout << "i == " << i << endl;
}

cin doesn't wait for input - the cout code gets executed with a random value
for i.

I'm using gcc from CVS, updated a few hours ago.

When I run the same code under gcc 2.95.3 it works fine.

Is this a problem with libstdc++-v3 or could my setup be wrong?

Thanks,
Yasir


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]