Index: src/station_func.h =================================================================== --- src/station_func.h (revision 14462) +++ src/station_func.h (working copy) @@ -7,6 +7,7 @@ #include "station_type.h" #include "sprite.h" +#include "oldpool.h" #include "rail_type.h" #include "road_type.h" #include "tile_type.h" @@ -17,7 +18,7 @@ void ModifyStationRatingAround(TileIndex tile, Owner owner, int amount, uint radius); /** A set of stations (\c const \c Station* ) */ -typedef std::set StationSet; +typedef std::set > StationSet; StationSet FindStationsAroundIndustryTile(TileIndex tile, int w, int h); Index: src/oldpool.h =================================================================== --- src/oldpool.h (revision 14462) +++ src/oldpool.h (working copy) @@ -155,6 +155,14 @@ } } +/** + * Template providing a predicate to allow STL containers of + * pointers to pool items to be sorted by index. + */ +template +struct PoolItemIndexLess { + bool operator()(const T* a, const T* b) const { return a->index < b->index; } +}; /** * Generalization for all pool items that are saved in the savegame.