summaryrefslogtreecommitdiff
path: root/svl
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2016-08-30 07:43:52 +0200
committerStephan Bergmann <sbergman@redhat.com>2016-08-30 07:43:52 +0200
commit5536aea8228778e00b9f1ca8199d858cd03780ad (patch)
treed244654bc3c5aa4e5b3a87df5f004ef61049996c /svl
parent20f6a6b159c69771dc0e087f63b6c701908e32e2 (diff)
Let OUStringLiteral1 take its arg as ctor arg, not template arg
...which makes it more flexible, can now also be used on non-const arguments. The drawback of the argument no longer being a compile-time constant is remedied by making the ctor constexpr. Change-Id: Ia4903a2cc86791fece92eac0cb8406b6659dd19d
Diffstat (limited to 'svl')
-rw-r--r--svl/qa/unit/svl.cxx8
-rw-r--r--svl/source/misc/lngmisc.cxx4
2 files changed, 6 insertions, 6 deletions
diff --git a/svl/qa/unit/svl.cxx b/svl/qa/unit/svl.cxx
index 9a7cb261c441..321e382ae6fd 100644
--- a/svl/qa/unit/svl.cxx
+++ b/svl/qa/unit/svl.cxx
@@ -1185,10 +1185,10 @@ void Test::testUserDefinedNumberFormats()
}
{ // tdf#79399 tdf#101462 Native Number Formats
sCode = "[NatNum5][$-0404]General\\ ";
- sExpected = OUStringLiteral1<22777>() + // 壹
- OUStringLiteral1<20336>() + // 佰
- OUStringLiteral1<36019>() + // 貳
- OUStringLiteral1<25342>() + // 拾
+ sExpected = OUStringLiteral1(22777) + // 壹
+ OUStringLiteral1(20336) + // 佰
+ OUStringLiteral1(36019) + // 貳
+ OUStringLiteral1(25342) + // 拾
" ";
checkPreviewString(aFormatter, sCode, 120, eLang, sExpected);
sCode = "[DBNum2][$-0404]General\\ ";
diff --git a/svl/source/misc/lngmisc.cxx b/svl/source/misc/lngmisc.cxx
index d0fe8b501dfe..1c7928fc6ba9 100644
--- a/svl/source/misc/lngmisc.cxx
+++ b/svl/source/misc/lngmisc.cxx
@@ -38,8 +38,8 @@ namespace linguistic
bool RemoveHyphens(OUString &rTxt)
{
sal_Int32 n = rTxt.getLength();
- rTxt = rTxt.replaceAll(OUStringLiteral1<SVT_SOFT_HYPHEN>(), "");
- rTxt = rTxt.replaceAll(OUStringLiteral1<SVT_HARD_HYPHEN>(), "");
+ rTxt = rTxt.replaceAll(OUStringLiteral1(SVT_SOFT_HYPHEN), "");
+ rTxt = rTxt.replaceAll(OUStringLiteral1(SVT_HARD_HYPHEN), "");
return n != rTxt.getLength();
}