https://bugs.freedesktop.org/show_bug.cgi?id=57950
Priority: medium
Bug ID: 57950
Assignee: [email protected]
Summary: Replace chained O(U)StringBuffer::append() with
operator+
Severity: enhancement
Classification: Unclassified
OS: All
Reporter: [email protected]
Hardware: Other
Status: UNCONFIRMED
Version: unspecified
Component: Libreoffice
Product: LibreOffice
The codebase contains code such as:
rtl::OUString aFileName =
rtl::OUStringBuffer().append("charts/chart").append(nCount).append(".xml").makeStringAndClear();
or
rtl::OUStringBuffer aName(msSeed);
aName.append(++mnImportedGraphicsCount);
aName.append(": ");
aName.append(rFixed);
pFrmFmt->SetName(aName.makeStringAndClear());
These can be more easily written (and later read) as:
OUString aFileName = "charts/chart" + OUString::valueOf(nCount) + ".xml";
or
pFrmFmt->SetName(OUString::valueOf(++mnImportedGraphicsCount) + ": " + rFixed);
All these chained calls to OStringBuffer::append() and OUStringBuffer::append()
can be simply replaced by usage of operator+ as written in the examples above.
--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Libreoffice-bugs mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs