From fdf4aa982f8265402ec6ecfa137bf2bc4052560d Mon Sep 17 00:00:00 2001 From: suke Date: Wed, 14 Feb 2007 13:57:59 +0000 Subject: [PATCH] * ext/win32ole/win32ole.c (ole_variant2val): VC++6 does not support VT_I8, VT_UI8. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@11741 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 5 +++++ ext/win32ole/win32ole.c | 18 ++++-------------- 2 files changed, 9 insertions(+), 14 deletions(-) diff --git a/ChangeLog b/ChangeLog index 7be2b9aecf..db3996b356 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Wed Feb 14 22:52:43 2007 Masaki Suketa + + * ext/win32ole/win32ole.c (ole_variant2val): VC++6 does not + support VT_I8, VT_UI8. + Wed Feb 14 22:10:21 2007 Koichi Sasada * configure.in: change stack limit to 2MB from 32MB. diff --git a/ext/win32ole/win32ole.c b/ext/win32ole/win32ole.c index 3743b369c7..7b31649c84 100644 --- a/ext/win32ole/win32ole.c +++ b/ext/win32ole/win32ole.c @@ -80,7 +80,7 @@ #define WC2VSTR(x) ole_wc2vstr((x), TRUE) -#define WIN32OLE_VERSION "0.9.6" +#define WIN32OLE_VERSION "0.9.7" typedef HRESULT (STDAPICALLTYPE FNCOCREATEINSTANCEEX) (REFCLSID, IUnknown*, DWORD, COSERVERINFO*, DWORD, MULTI_QI*); @@ -1611,32 +1611,22 @@ ole_variant2val(VARIANT *pvar) else obj = INT2NUM((long)V_I4(pvar)); break; +#if (_MSC_VER >= 1300) || defined(__CYGWIN__) || defined(__MINGW32__) case VT_I8: - /* - if(V_ISBYREF(pvar)) - obj = INT2NUM(*V_I8REF(pvar)); - else - obj = INT2NUM(V_I8(pvar)); - */ #ifdef HAVE_LONG_LONG obj = LL2NUM(V_I8(pvar)); #else obj = INT2NUM(V_I8(pvar)); -#endif +#endif break; case VT_UI8: - /* - if(V_ISBYREF(pvar)) - obj = INT2NUM(*V_UI8REF(pvar)); - else - obj = INT2NUM(V_UI8(pvar)); - */ #ifdef HAVE_LONG_LONG obj = ULL2NUM(V_UI8(pvar)); #else obj = UINT2NUM(V_UI8(pvar)); #endif break; +#endif /* (_MSC_VER >= 1300) || defined(__CYGWIN__) || defined(__MINGW32__) */ case VT_R4: if(V_ISBYREF(pvar)) obj = rb_float_new(*V_R4REF(pvar));