summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2021-11-12 13:16:39 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2021-11-13 06:26:32 +0100
commit0dbde576f57395c9315e5da8c43e9aedf9094953 (patch)
treeaae77b3444d5bd29790b2cf2a13729209145b570
parent79589afe173ba8f17bfbbc6b38f0dfbc5fd9e0c9 (diff)
make SwNodeOffset operator+ and operator- inline
forgot to do this spotted by llunak Change-Id: I5e8c723850f77346789ea0b1fb364f5e0d44ae42 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125097 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
-rw-r--r--sw/inc/nodeoffset.hxx6
1 files changed, 4 insertions, 2 deletions
diff --git a/sw/inc/nodeoffset.hxx b/sw/inc/nodeoffset.hxx
index 0911fdb67b23..035925855b31 100644
--- a/sw/inc/nodeoffset.hxx
+++ b/sw/inc/nodeoffset.hxx
@@ -17,14 +17,16 @@ typedef o3tl::strong_int<sal_Int32, struct Tag_SwNodeOffset> SwNodeOffset;
/* Just to make it easier to write arithmetic with these types */
template <typename T>
-typename std::enable_if<std::is_signed<T>::value, SwNodeOffset>::type operator+(SwNodeOffset a, T n)
+inline typename std::enable_if<std::is_signed<T>::value, SwNodeOffset>::type
+operator+(SwNodeOffset a, T n)
{
return a + SwNodeOffset(n);
}
/* Just to make it easier to write arithmetic with these types */
template <typename T>
-typename std::enable_if<std::is_signed<T>::value, SwNodeOffset>::type operator-(SwNodeOffset a, T n)
+inline typename std::enable_if<std::is_signed<T>::value, SwNodeOffset>::type
+operator-(SwNodeOffset a, T n)
{
return a - SwNodeOffset(n);
}