Codechange: Use functor for Kdtree's XYFunc. (#13074)

Kdtree uses a function pointer and incorrectly calls it a functor. The function pointer needs to be passed on instantiaton.

Instead, use an actual functor. This simplifies instantiation.
This commit is contained in:
2024-11-19 20:29:56 +00:00
committed by GitHub
parent 369ea29e1e
commit fc8685d618
8 changed files with 40 additions and 28 deletions

View File

@@ -50,7 +50,7 @@
#include "safeguards.h"
TownKdtree _town_local_authority_kdtree(&Kdtree_TownXYFunc);
TownKdtree _town_local_authority_kdtree{};
typedef GUIList<const Town*, const bool &> GUITownList;