Modernize `std::min_element` with ranges

This commit is contained in:
mitaclaw 2024-09-29 11:12:44 -07:00
parent c99a0c25e0
commit e572081ac3
1 changed files with 1 additions and 1 deletions

View File

@ -846,7 +846,7 @@ void AssemblerWidget::CloseTab(int index, AsmEditor* editor)
int AssemblerWidget::AllocateTabNum() int AssemblerWidget::AllocateTabNum()
{ {
auto min_it = std::min_element(m_free_editor_nums.begin(), m_free_editor_nums.end()); auto min_it = std::ranges::min_element(m_free_editor_nums);
if (min_it == m_free_editor_nums.end()) if (min_it == m_free_editor_nums.end())
{ {
return m_unnamed_editor_count++; return m_unnamed_editor_count++;