svtools/source/misc/langtab.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
New commits: commit 25ece0a2c15f0dc637e0fb607aaa5114b2739998 Author: Simon Chenery <simon_chen...@yahoo.com> AuthorDate: Mon Mar 24 08:10:53 2025 +0100 Commit: Ilmari Lauhakangas <ilmari.lauhakan...@libreoffice.org> CommitDate: Fri May 30 19:33:42 2025 +0200 tdf#147021 avoid use of SAL_N_ELEMENTS macro in langtab.cxx Change-Id: I7f27496835e35e049261aadfd65c9c7e7a38202d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/183253 Tested-by: Jenkins Tested-by: Ilmari Lauhakangas <ilmari.lauhakan...@libreoffice.org> Reviewed-by: Ilmari Lauhakangas <ilmari.lauhakan...@libreoffice.org> diff --git a/svtools/source/misc/langtab.cxx b/svtools/source/misc/langtab.cxx index dfacf5663e61..56dd955fac39 100644 --- a/svtools/source/misc/langtab.cxx +++ b/svtools/source/misc/langtab.cxx @@ -190,9 +190,9 @@ static OUString lcl_getDescription( const LanguageTag& rTag ) SvtLanguageTableImpl::SvtLanguageTableImpl() { - for (size_t i = 0; i < SAL_N_ELEMENTS(STR_ARR_SVT_LANGUAGE_TABLE); ++i) + for (const auto& [rResId, rType] : STR_ARR_SVT_LANGUAGE_TABLE) { - m_aStrings.emplace_back(SvtResId(STR_ARR_SVT_LANGUAGE_TABLE[i].first), STR_ARR_SVT_LANGUAGE_TABLE[i].second); + m_aStrings.emplace_back(SvtResId(rResId), rType); } auto xNA = officecfg::VCL::ExtraLanguages::get();