summaryrefslogtreecommitdiff
path: root/include/comphelper
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2018-07-26 09:55:57 +0200
committerStephan Bergmann <sbergman@redhat.com>2018-07-26 12:30:20 +0200
commitbd8cb3ff962417e3f79ae19e7d802e433ea174ac (patch)
tree0e02e9a62a30f3793b5259f0f1e007878bf510b6 /include/comphelper
parent11d87b35474b642e99e7aa397aa18992c1bc20c9 (diff)
Iterators must be CopyAssignable
...so make sure the (implicitly defined) copy assignment op is not deleted and has sane semantics Change-Id: If34cb5bd1ef250505a4c876ab78aba2a3d5dfc21 Reviewed-on: https://gerrit.libreoffice.org/58039 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'include/comphelper')
-rw-r--r--include/comphelper/stl_types.hxx10
1 files changed, 3 insertions, 7 deletions
diff --git a/include/comphelper/stl_types.hxx b/include/comphelper/stl_types.hxx
index c3539bbe21a0..bf8cc2b70494 100644
--- a/include/comphelper/stl_types.hxx
+++ b/include/comphelper/stl_types.hxx
@@ -143,21 +143,17 @@ public:
typedef size_t difference_type;
OUStringBufferAppender(OUStringBuffer & i_rBuffer)
- : m_rBuffer(i_rBuffer) { }
- Self & operator=(Self const &)
- { // MSVC 2013 with non-debug runtime requires this in xutility.hpp:289
- return *this;
- }
+ : m_rBuffer(&i_rBuffer) { }
Self & operator=(OUString const & i_rStr)
{
- m_rBuffer.append( i_rStr );
+ m_rBuffer->append( i_rStr );
return *this;
}
Self & operator*() { return *this; } // so operator= works
Self & operator++() { return *this; }
private:
- OUStringBuffer & m_rBuffer;
+ OUStringBuffer * m_rBuffer;
};
/** algorithm similar to std::copy, but inserts a separator between elements.