Silently passing wrong input for good one

Martin Sebor sebor@roguewave.com
Sat Oct 22 00:59:00 GMT 2005


Paolo Carlini wrote:
[...]
> Another option would be to just fail in that case. But then we have to
> avoid mentioning scanf

I think that's a given if our goal is to fix issue 23.

> or, at least, ask the C committee for a
> clarification about the behavior of the latter, because, at variance
> with EXAMPLE 3 that interestingly you mention, *all* the implementions
> that you mentioned, *succesfully* extract -3.0,

Which is incorrect. How funny!

> the divergence in
> behavior is only about what happens afterwards!

I can't say I'm teribly surprised in this corner case. Still,
I would expect libc implementers to try all the examples in
the standard and either get them to work or file a defect.

Martin



More information about the Libstdc++ mailing list