summaryrefslogtreecommitdiff
path: root/src/pugixml.cpp
diff options
context:
space:
mode:
authorArseny Kapoulkine <arseny.kapoulkine@gmail.com>2014-02-08 21:59:14 +0000
committerArseny Kapoulkine <arseny.kapoulkine@gmail.com>2014-02-08 21:59:14 +0000
commit2bd99cff86d3e8853e0cf776ae0cb6e6a18f2bb3 (patch)
treebac1bca21011a105b269f9686129fdea786705d5 /src/pugixml.cpp
parent44d3ae5e9014c3f52c67d8f593605b77752264e6 (diff)
Enable long long support for C++11 and for MSVC 2008+
git-svn-id: http://pugixml.googlecode.com/svn/trunk@967 99668b35-9821-0410-8761-19e4c4f06640
Diffstat (limited to 'src/pugixml.cpp')
-rw-r--r--src/pugixml.cpp24
1 files changed, 20 insertions, 4 deletions
diff --git a/src/pugixml.cpp b/src/pugixml.cpp
index 874d611..10572eb 100644
--- a/src/pugixml.cpp
+++ b/src/pugixml.cpp
@@ -3394,9 +3394,17 @@ PUGI__NS_BEGIN
int base = get_integer_base(value);
#ifdef PUGIXML_WCHAR_MODE
- return wcstoll(value, 0, base);
+ #ifdef PUGI__MSVC_CRT_VERSION
+ return _wcstoi64(value, 0, base);
+ #else
+ return wcstoll(value, 0, base);
+ #endif
#else
- return strtoll(value, 0, base);
+ #ifdef PUGI__MSVC_CRT_VERSION
+ return _strtoi64(value, 0, base);
+ #else
+ return strtoll(value, 0, base);
+ #endif
#endif
}
@@ -3407,9 +3415,17 @@ PUGI__NS_BEGIN
int base = get_integer_base(value);
#ifdef PUGIXML_WCHAR_MODE
- return wcstoull(value, 0, base);
+ #ifdef PUGI__MSVC_CRT_VERSION
+ return _wcstoui64(value, 0, base);
+ #else
+ return wcstoull(value, 0, base);
+ #endif
#else
- return strtoull(value, 0, base);
+ #ifdef PUGI__MSVC_CRT_VERSION
+ return _strtoui64(value, 0, base);
+ #else
+ return strtoull(value, 0, base);
+ #endif
#endif
}
#endif