scanf parsing

diamond@tkovoa diamond at tkou02.enet.dec.com
Mon Dec 24 16:55:20 AEST 1990


Subject: Re: scanf parsing
In article <1990Dec24.031228.5880 at athena.mit.edu> tada at athena.mit.edu (Michael J Zehr) writes:
 
>what (if anything) does the ANSI spec say about scanf using %f format
>and strtod for the following strings?
 
>"1ea"
I believe that an interpretation ruling on this issue was posted a few
months ago, stating that the "a" would be pushed back, the "1" and "e"
are lost, and the result is matching failure.
 
>"1e "
.-1s/"a"/" "
 
>"1e1e"
This one does not seem to need interpretation.  1e1 is matched successfully
and the last "e" is pushed back.
 
--
Norman Diamond       diamond at tkov50.enet.dec.com
If this were the company's opinion, I wouldn't be allowed to post it.



More information about the Comp.std.c mailing list