Author: sebor
Date: Wed Jun 14 18:03:32 2006
New Revision: 414419
URL: http://svn.apache.org/viewvc?rev=414419&view=rev
Log:
2006-06-14 Martin Sebor <[EMAIL PROTECTED]>
* cwchar (swprintf, vswprintf): More hackery for the various
strains of the disease known as MSVC.
Modified:
incubator/stdcxx/trunk/include/ansi/cwchar
Modified: incubator/stdcxx/trunk/include/ansi/cwchar
URL:
http://svn.apache.org/viewvc/incubator/stdcxx/trunk/include/ansi/cwchar?rev=414419&r1=414418&r2=414419&view=diff
==============================================================================
--- incubator/stdcxx/trunk/include/ansi/cwchar (original)
+++ incubator/stdcxx/trunk/include/ansi/cwchar Wed Jun 14 18:03:32 2006
@@ -310,12 +310,24 @@
#if _MSC_VER < 1310 // MSVC < 7.1 or (better yet) not MSVC
-extern "C" int swprintf (wchar_t*, size_t, const wchar_t*, ...);
+extern "C" {
-#else // MSVC 7.1 and above
+_RWSTD_DLLIMPORT int
+swprintf (wchar_t*, size_t, const wchar_t*, ...);
+
+} // extern "C"
+
+#elif _MSC_VER == 1310 // MSVC 7.1
+
+// MSVC 8.0 defines the C++ overload of swprintf() inline
+/* extern "C++" */ _RWSTD_DLLIMPORT int
+swprintf (wchar_t*, size_t, const wchar_t*, ...);
+
+#else // MSVC 8.0 and above
// MSVC 7.1 declares two overloads of swprintf()
-/* extern "C++" */ int swprintf (wchar_t*, size_t, const wchar_t*, ...);
+/* extern "C++" */ int
+swprintf (wchar_t*, size_t, const wchar_t*, ...);
#endif // MSVC
@@ -379,13 +391,24 @@
#if _MSC_VER < 1310 // MSVC < 7.1 or (better yet) not MSVC
-extern "C" int vswprintf (wchar_t*, size_t, const wchar_t*, _RWSTD_VA_LIST);
+extern "C" {
+
+_RWSTD_DLLIMPORT int
+vswprintf (wchar_t*, size_t, const wchar_t*, _RWSTD_VA_LIST);
+
+} // extern "C"
+
+#elif _MSC_VER == 1310 // MSVC 7.1
+
+// MSVC 7.1 declares two overloads of swprintf()
+/* extern "C++" */ _RWSTD_DLLIMPORT int
+swprintf (wchar_t*, size_t, const wchar_t*, ...);
-#else // MSVC 7.1 and above
+#else // MSVC 8.0 and above
-// MSVC 7.1 declares two overloads of vswprintf()
-/* extern "C++" */
-int vswprintf (wchar_t*, size_t, const wchar_t*, _RWSTD_VA_LIST);
+// MSVC 8.0 defines the C++ overload of vswprintf() inline
+/* extern "C++" */ int
+vswprintf (wchar_t*, size_t, const wchar_t*, _RWSTD_VA_LIST);
#endif // MSVC