summaryrefslogtreecommitdiff
path: root/include/rtl/string.h
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2019-10-30 08:41:43 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2019-10-31 07:02:09 +0100
commitab35d2ded153b0129fed16f9a7e882c8600933e6 (patch)
tree13f1776117f743c34761b6a31ca93f80020e20d3 /include/rtl/string.h
parent877d0c2c211067e8c1b5fdff0f6d9703c94767e9 (diff)
tdf#125688 speed up load of change-tracking ODS
by 10%, by avoiding an OUString construction in a hot path through XMLTextColumnContext_Impl::XMLTextColumnContext_Impl -> sax::Convert::convertNumber Also changed XMLTextAnimationStepPropertyHdl::importXML to take advantage of the modified convertNumber passing convention. Change-Id: I4e5503dbb094c88a09af8b6dc8c22b6c53f9eb75 Reviewed-on: https://gerrit.libreoffice.org/81726 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'include/rtl/string.h')
-rw-r--r--include/rtl/string.h25
1 files changed, 25 insertions, 0 deletions
diff --git a/include/rtl/string.h b/include/rtl/string.h
index 4996e1d07b4d..81322b186875 100644
--- a/include/rtl/string.h
+++ b/include/rtl/string.h
@@ -783,6 +783,31 @@ SAL_DLLPUBLIC sal_uInt32 SAL_CALL rtl_str_toUInt32(
SAL_DLLPUBLIC sal_Int64 SAL_CALL rtl_str_toInt64(
const sal_Char * str, sal_Int16 radix ) SAL_THROW_EXTERN_C();
+/** Interpret a string as a long integer.
+
+ This function cannot be used for language-specific conversion. The string
+ must be null-terminated.
+
+ @param str
+ a null-terminated string.
+
+ @param radix
+ the radix. Must be between RTL_STR_MIN_RADIX (2) and RTL_STR_MAX_RADIX
+ (36), inclusive.
+
+ @param nStrLength
+ number of sal_Chars to process
+
+ @return
+ the long integer value represented by the string, or 0 if the string does
+ not represent a long integer.
+
+ @internal
+ @since LibreOffice 6.4
+*/
+SAL_DLLPUBLIC sal_Int64 SAL_CALL rtl_str_toInt64_WithLength(
+ const sal_Char * str, sal_Int16 radix, sal_Int32 nStrLength ) SAL_THROW_EXTERN_C();
+
/** Interpret a string as an unsigned long integer.
This function cannot be used for language-specific conversion. The string