]> git.saurik.com Git - wxWidgets.git/commitdiff
Fix wxULongLong::ToDouble() for MSVC.
authorVadim Zeitlin <vadim@wxwidgets.org>
Wed, 27 Apr 2011 18:51:00 +0000 (18:51 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Wed, 27 Apr 2011 18:51:00 +0000 (18:51 +0000)
The conversion of wxULongLong to double was broken for MSVC by r40658 which
was supposed to correct some unspecified compilation problem but this code
seems to compile fine with at least recent versions of MSVC and, in any case,
correcting compilation only for the code to work incorrectly during run-time
doesn't look like a good idea.

This fixes current unit test failures in wxMSW.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67634 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

include/wx/longlong.h

index b90bd71873dd997ef6fdec26e84aca07ee93a3da..de468676fd401fd0c889d9a59d0a3d61a3a63aef 100644 (file)
@@ -411,11 +411,7 @@ public:
     }
 
         // convert to double
-#ifdef _MSC_VER
-    double ToDouble() const { return wx_truncate_cast(double, (__int64) m_ll); }
-#else
     double ToDouble() const { return wx_truncate_cast(double, m_ll); }
-#endif
 
     // operations
         // addition