summaryrefslogtreecommitdiff
path: root/include/oox/export
diff options
context:
space:
mode:
authorMike Kaganski <mike.kaganski@collabora.com>2017-09-11 09:15:46 +0300
committerMike Kaganski <mike.kaganski@collabora.com>2017-09-11 09:22:28 +0200
commitf0809a84b6c85a254bc23c5f55f86116d14a145d (patch)
treef829cbd18bd0611fa3e2cbdd8356b173d7bc43ec /include/oox/export
parent4c09f8e087cae598efbb78759110c03ed10e3a3a (diff)
include/oox/export/utils.hxx: make functions constexpr
Change-Id: I7606b54fb7cef831c3f9a8580260aa880c7f4db4 Reviewed-on: https://gerrit.libreoffice.org/42149 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Diffstat (limited to 'include/oox/export')
-rw-r--r--include/oox/export/utils.hxx8
1 files changed, 4 insertions, 4 deletions
diff --git a/include/oox/export/utils.hxx b/include/oox/export/utils.hxx
index d94d6c4228ae..927987115a60 100644
--- a/include/oox/export/utils.hxx
+++ b/include/oox/export/utils.hxx
@@ -34,7 +34,7 @@ inline OString I64S_(sal_Int64 x) { return OString::number(x); }
* @return const char* literal "true" for true value, or literal "false"
* for false value.
*/
-static inline const char* ToPsz(bool b)
+static constexpr const char* ToPsz(bool b)
{
return b ? "true" : "false";
}
@@ -42,7 +42,7 @@ static inline const char* ToPsz(bool b)
/**
* @return literal "1" for true value, or literal "0" for false value.
*/
-static inline const char* ToPsz10(bool b)
+static constexpr const char* ToPsz10(bool b)
{
// xlsx seems to use "1" or "0" for boolean values. I wonder it ever uses
// the "true" "false" variant.
@@ -51,12 +51,12 @@ static inline const char* ToPsz10(bool b)
#define USS(x) OUStringToOString( x, RTL_TEXTENCODING_UTF8 ).getStr()
-static inline sal_Int64 PPTtoEMU( sal_Int32 nPPT )
+static constexpr sal_Int64 PPTtoEMU( sal_Int32 nPPT )
{
return (sal_Int64)( (double)nPPT * 1587.5 );
}
-static inline sal_Int64 TwipsToEMU( sal_Int32 nTwips )
+static constexpr sal_Int64 TwipsToEMU( sal_Int32 nTwips )
{
return sal_Int64( nTwips ) * 635;
}