mirror of https://github.com/OpenTTD/OpenTTD
(svn r6279) -Codechange (r1525): Use proper const pointers for functions that do not change them .
parent
538ab07b69
commit
d2c239b590
10
vehicle.h
10
vehicle.h
|
@ -426,11 +426,10 @@ static inline Order *GetLastVehicleOrder(const Vehicle *v)
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Get the first vehicle of a shared-list, so we only have to walk forwards */
|
/* Get the first vehicle of a shared-list, so we only have to walk forwards */
|
||||||
static inline Vehicle *GetFirstVehicleFromSharedList(Vehicle *v)
|
static inline Vehicle *GetFirstVehicleFromSharedList(const Vehicle *v)
|
||||||
{
|
{
|
||||||
Vehicle *u = v;
|
Vehicle *u = (Vehicle *)v;
|
||||||
while (u->prev_shared != NULL)
|
while (u->prev_shared != NULL) u = u->prev_shared;
|
||||||
u = u->prev_shared;
|
|
||||||
|
|
||||||
return u;
|
return u;
|
||||||
}
|
}
|
||||||
|
@ -462,8 +461,7 @@ PalSpriteID GetVehiclePalette(const Vehicle *v);
|
||||||
* Best is to have a virtual value for it when it needs to change again */
|
* Best is to have a virtual value for it when it needs to change again */
|
||||||
#define STATUS_BAR 5
|
#define STATUS_BAR 5
|
||||||
|
|
||||||
|
extern const uint32 _send_to_depot_proc_table[];
|
||||||
#define CMD_SEND_TO_DEPOT(x) _send_to_depot_proc_table[ x - VEH_Train]
|
#define CMD_SEND_TO_DEPOT(x) _send_to_depot_proc_table[ x - VEH_Train]
|
||||||
|
|
||||||
extern const uint32 _send_to_depot_proc_table[];
|
|
||||||
|
|
||||||
#endif /* VEHICLE_H */
|
#endif /* VEHICLE_H */
|
||||||
|
|
Loading…
Reference in New Issue