by Michael S. Kaplan, published on 2005/08/21 21:30 -04:00, original URI: http://blogs.msdn.com/b/michkap/archive/2005/08/21/454327.aspx
Serge Wautier asked:
I just blogged about GetNumberFormat() and why it may be confusing to users.
It led me to wonder why GetNumberFormat() is not used by the CRT, such as in printf-like functions, even though GetDateFormat() is used by the same CRT.
Do you know why ? Is there any tricky answer or is it just because of general "backward compatibility" as I described in my post ?
TIA,
Serge.
http://www.apptranslator.com/blog/2005/08/getnumberformat-was-25-years-late.html
A fascinating question, but one I do not really know the answer to!
If I had to guess, I would think that the differences between number formatting and date formatting (i.e. that date formatting is mostly based on format strings, while number formatting is not based on them at all), since the method used for number formatting is harder to integrate into the parsing algorithms that are used by the C runtime. But that is 100% speculation without any real knowledge of why the difference in behavior might exist.
But I thought I would put it up here in case any of the CRT folks might want to weigh in with an answer? I know a couple of them frequent this blog, perhaps one of them knows the backstory here....
# Serge Wautier on 22 Aug 2005 2:56 AM: