more convenient.
Maybe we could improve it using FormatMessage instead of FormatV, to make
internationalization support better, in particular: what Mihai calls the
problem of "Yoda Speak":
http://www.mihai-nita.net/article.php?artID 060430a#csfmtmsg
I return a CString, and don't use any fixed-size TCHAR array. I would
never consider
something as horrible as using a static buffer.
I tend to return CString (99.9%), but when there is a specific need for
performance (0.1%, not a general case), I would use a static TCHAR buffer.
If the caller wants to store the string, he can save it in a CString, but
if he doesn't need that, we save a deep copy with copy ctor (... I don't
know if RVO optimization could be applied in that case). However, I'm
aware that using the static buffer is not good for multithreading.
Giov