Piotr Caban : msvcp80: Add ostream::operator<<(unsigned short) implementation.

Alexandre Julliard julliard at winehq.org
Tue Sep 24 15:16:48 CDT 2013


Module: wine
Branch: master
Commit: 435cf5cebc82ebff92fa0167c18b80fdcc9b8542
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=435cf5cebc82ebff92fa0167c18b80fdcc9b8542

Author: Piotr Caban <piotr at codeweavers.com>
Date:   Tue Sep 24 15:49:23 2013 +0200

msvcp80: Add ostream::operator<<(unsigned short) implementation.

---

 dlls/msvcp80/ios.c        |   26 ++++++++++++++++++++------
 dlls/msvcp80/msvcp80.spec |    4 ++--
 2 files changed, 22 insertions(+), 8 deletions(-)

diff --git a/dlls/msvcp80/ios.c b/dlls/msvcp80/ios.c
index de0033d..9cdaf1d 100644
--- a/dlls/msvcp80/ios.c
+++ b/dlls/msvcp80/ios.c
@@ -6540,19 +6540,15 @@ basic_ostream_wchar* __thiscall basic_ostream_short_print_short(basic_ostream_wc
                 basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this))->loc));
 }
 
-/* ??6?$basic_ostream at _WU?$char_traits at _W@std@@@std@@QAEAAV01 at G@Z */
-/* ??6?$basic_ostream at _WU?$char_traits at _W@std@@@std@@QEAAAEAV01 at G@Z */
-DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_ushort, 8)
-basic_ostream_wchar* __thiscall basic_ostream_wchar_print_ushort(basic_ostream_wchar *this, unsigned short val)
+static basic_ostream_wchar* basic_ostream_print_ushort(basic_ostream_wchar *this, unsigned short val, const num_put *numput)
 {
     basic_ios_wchar *base = basic_ostream_wchar_get_basic_ios(this);
     int state = IOSTATE_goodbit;
 
-    TRACE("(%p %u)\n", this, val);
+    TRACE("(%p %d)\n", this, val);
 
     if(basic_ostream_wchar_sentry_create(this)) {
         basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
-        const num_put *numput = num_put_wchar_use_facet(strbuf->loc);
         ostreambuf_iterator_wchar dest = {0, strbuf};
 
         num_put_wchar_put_ulong(numput, &dest, dest, &base->base, basic_ios_wchar_fill_get(base), val);
@@ -6563,6 +6559,24 @@ basic_ostream_wchar* __thiscall basic_ostream_wchar_print_ushort(basic_ostream_w
     return this;
 }
 
+/* ??6?$basic_ostream at _WU?$char_traits at _W@std@@@std@@QAEAAV01 at G@Z */
+/* ??6?$basic_ostream at _WU?$char_traits at _W@std@@@std@@QEAAAEAV01 at G@Z */
+DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_ushort, 8)
+basic_ostream_wchar* __thiscall basic_ostream_wchar_print_ushort(basic_ostream_wchar *this, unsigned short val)
+{
+    return basic_ostream_print_ushort(this, val, num_put_wchar_use_facet(
+                basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this))->loc));
+}
+
+/* ??6?$basic_ostream at GU?$char_traits at G@std@@@std@@QAEAAV01 at G@Z */
+/* ??6?$basic_ostream at GU?$char_traits at G@std@@@std@@QEAAAEAV01 at G@Z */
+DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_ushort, 8)
+basic_ostream_wchar* __thiscall basic_ostream_short_print_ushort(basic_ostream_wchar *this, unsigned short val)
+{
+    return basic_ostream_print_ushort(this, val, num_put_short_use_facet(
+                basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this))->loc));
+}
+
 static basic_ostream_wchar* basic_ostream_print_int(basic_ostream_wchar *this, int val, const num_put *numput)
 {
     basic_ios_wchar *base = basic_ostream_wchar_get_basic_ios(this);
diff --git a/dlls/msvcp80/msvcp80.spec b/dlls/msvcp80/msvcp80.spec
index 0a913ef..64e25b7 100644
--- a/dlls/msvcp80/msvcp80.spec
+++ b/dlls/msvcp80/msvcp80.spec
@@ -1606,8 +1606,8 @@
 @ cdecl -arch=win64 ??6?$basic_ostream at DU?$char_traits at D@std@@@std@@QEAAAEAV01 at _N@Z(ptr long) basic_ostream_char_print_bool
 @ thiscall -arch=i386 ??6?$basic_ostream at GU?$char_traits at G@std@@@std@@QAEAAV01 at F@Z(ptr long) basic_ostream_short_print_short
 @ cdecl -arch=win64 ??6?$basic_ostream at GU?$char_traits at G@std@@@std@@QEAAAEAV01 at F@Z(ptr long) basic_ostream_short_print_short
-@ stub -arch=win32 ??6?$basic_ostream at GU?$char_traits at G@std@@@std@@QAEAAV01 at G@Z
-@ stub -arch=win64 ??6?$basic_ostream at GU?$char_traits at G@std@@@std@@QEAAAEAV01 at G@Z
+@ thiscall -arch=win32 ??6?$basic_ostream at GU?$char_traits at G@std@@@std@@QAEAAV01 at G@Z(ptr long) basic_ostream_short_print_ushort
+@ cdecl -arch=win64 ??6?$basic_ostream at GU?$char_traits at G@std@@@std@@QEAAAEAV01 at G@Z(ptr long) basic_ostream_short_print_ushort
 @ thiscall -arch=i386 ??6?$basic_ostream at GU?$char_traits at G@std@@@std@@QAEAAV01 at H@Z(ptr long) basic_ostream_short_print_int
 @ cdecl -arch=win64 ??6?$basic_ostream at GU?$char_traits at G@std@@@std@@QEAAAEAV01 at H@Z(ptr long) basic_ostream_short_print_int
 @ thiscall -arch=i386 ??6?$basic_ostream at GU?$char_traits at G@std@@@std@@QAEAAV01 at I@Z(ptr long) basic_ostream_short_print_uint




More information about the wine-cvs mailing list