Re: standard input from console not working in Xcode 4.5
Re: standard input from console not working in Xcode 4.5
- Subject: Re: standard input from console not working in Xcode 4.5
- From: Dave Reed <email@hidden>
- Date: Fri, 21 Sep 2012 12:37:11 -0400
That sort of works, but seems to require switching back and forth after every character. Or perhaps I'm missing which drop down you are saying to toggle.
In case anyone from Apple is reading this, the radar is: rdar://12346183
Thanks,
Dave
On Sep 21, 2012, at 11:20 AM, Mikkel Islay wrote:
> Dave,
>
> I have encountered that issue as well.
> You can force a refresh of the console by selecting a different output in the drop-down menu and then selecting target output again, or read from a ifstream for more complex input.
>
> Mikkel
>
> On 21 Sep 2012, at 16:52, email@hidden wrote:
>
>> If I create a simple command line C++ program in Xcode 4.5 such as:
>>
>> #include <iostream>
>> using namespace std;
>> int main(int argc, const char * argv[])
>> {
>> int x;
>> cout << "enter x: ";
>> cin >> x;
>> cout << x << endl;
>> return 0;
>> }
>>
>> When I go to type in a value for x in the console, only the first digit is displayed as you type it although all digits are read:
>>
>> If I type: 123
>> You only see the 1, but x does contain 123 as the next output line shows.
>>
>> I've seen this on three separate machines, two with 10.8 and one with 10.7.
>>
>> Yes, I'll file a radar, but does anyone know a workaround (I can run the program from the Terminal fine) as this is driving my students nuts.
>>
>> Thanks,
>> Dave
>>
>> _______________________________________________
>> Do not post admin requests to the list. They will be ignored.
>> Xcode-users mailing list (email@hidden)
>> Help/Unsubscribe/Update your Subscription:
>>
>> This email sent to email@hidden
>
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden