Connecting Tech Pros Worldwide Help | Site Map

Re: (part 25) Han from China answers your C questions

  #1  
Old November 17th, 2008, 03:25 PM
Andrey Tarasevich
Guest
 
Posts: n/a
Nomen Nescio wrote:
Quote:
>
Irrelevant sequence point (for your case) of possible interest:
>
"After the actions associated with each formatted
input/output format conversion specifier"
>
I have no idea why that would be a sequence point. Taking the
output conversions, my guess would be so that something like
%n can function. Am I right, my dear audience of 1 or 2 people?
This sequence point is there to allow you to use code like

double d;
scanf("%lf %lf", &d, &d);

without worrying about the inner workings of 'scanf' violating the
requirements of 5/4 in this case, i.e. worrying about whether internally
'scanf' will attempt to modify 'd' twice without an intervening sequence
point or not.

--
Best regards,
Andrey Tarasevich
Closed Thread


Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: (part 1) Han from China answers your C questions Kelsey Bjarnason answers 33 November 10th, 2008 11:05 PM