From 8d3d136da7df3dd944b30119f919dec4f29eb3bf Mon Sep 17 00:00:00 2001 From: Dane Springmeyer Date: Fri, 12 Jun 2015 12:38:22 -0700 Subject: [PATCH] fix hang on windows in pixel_cast - manifested converting double -> int64_t. - it is unclear why this explicitness is needed on windows to avoid greater calling itself. But it is clear that the static_cast() is not enough for the template deduction to match the case automatically - Making this explicit is probably better anyway, but odd it is needed. - Finishes closing #2893, refs #2893, amends 96f7120ecc11 and d29a0f18b1fb9c - Seen with both VS 2014 CTP 4 and VS 2015 Preview --- include/mapnik/pixel_cast.hpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/mapnik/pixel_cast.hpp b/include/mapnik/pixel_cast.hpp index 698ca7dfc..a68501511 100644 --- a/include/mapnik/pixel_cast.hpp +++ b/include/mapnik/pixel_cast.hpp @@ -99,11 +99,11 @@ struct numeric_compare::value && std::is_floating_point::value)>::type> { static inline bool less(T t, S s) { - return less(static_cast(t),static_cast(s)); + return numeric_compare::less(static_cast(t),static_cast(s)); } static inline bool greater(T t, S s) { - return greater(static_cast(t),static_cast(s)); + return numeric_compare::greater(static_cast(t),static_cast(s)); } };