diff options
author | Mike Kaganski <mike.kaganski@collabora.com> | 2024-04-29 01:31:19 +0500 |
---|---|---|
committer | Mike Kaganski <mike.kaganski@collabora.com> | 2024-04-30 06:20:50 +0200 |
commit | ea9367037232054a576f1e6aabffeb3a62ffa44b (patch) | |
tree | ea5c755830b87fc140e9c3ce027b4957956fae48 /include | |
parent | e82c9633e4f9bc4590bd6cd8d2a82a974ddaf00f (diff) |
Drop some uses of css::uno::Sequence::getConstArray ...
where it was obsoleted by commits 2484de6728bd11bb7949003d112f1ece2223c7a1
(Remove non-const Sequence::begin()/end() in internal code, 2021-10-15) and
fb3c04bd1930eedacd406874e1a285d62bbf27d9 (Drop non-const Sequence::operator[]
in internal code 2021-11-05).
Change-Id: I4ccc647bb794515c8c11f8dfd9a26563f4aa094b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/166819
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Tested-by: Jenkins
Diffstat (limited to 'include')
-rw-r--r-- | include/comphelper/namedvaluecollection.hxx | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/include/comphelper/namedvaluecollection.hxx b/include/comphelper/namedvaluecollection.hxx index b92646e40a11..aa30df9932b4 100644 --- a/include/comphelper/namedvaluecollection.hxx +++ b/include/comphelper/namedvaluecollection.hxx @@ -302,12 +302,8 @@ namespace comphelper css::uno::Sequence< VALUE_TYPE > aValues; *this >>= aValues; css::uno::Sequence< css::uno::Any > aWrappedValues( aValues.getLength() ); - - css::uno::Any* pO = aWrappedValues.getArray(); - const VALUE_TYPE* pV = aValues.getConstArray(); - const sal_Int32 nLen = aValues.getLength(); - for( sal_Int32 i = 0; i < nLen; ++i ) - *(pO++) = css::uno::Any( *(pV++) ); + std::transform(aValues.begin(), aValues.end(), aWrappedValues.getArray(), + [](const auto& val) { return css::uno::Any(val); }); return aWrappedValues; } |