Codechange: Use std::unique_ptr for ScriptList::sorter. (#13517)

Avoids manual pointer management.
This commit is contained in:
Peter Nelson
2025-02-10 19:20:52 +00:00
committed by GitHub
parent faadf00a6a
commit 687829fa14
2 changed files with 11 additions and 13 deletions

View File

@@ -36,7 +36,7 @@ public:
static const bool SORT_DESCENDING = false;
private:
ScriptListSorter *sorter; ///< Sorting algorithm
std::unique_ptr<ScriptListSorter> sorter; ///< Sorting algorithm
SorterType sorter_type; ///< Sorting type
bool sort_ascending; ///< Whether to sort ascending or descending
bool initialized; ///< Whether an iteration has been started