[Freeciv-Dev] (PR#10375) [Patch] city_range_iterate cleanup
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: |
undisclosed-recipients: ; |
Subject: |
[Freeciv-Dev] (PR#10375) [Patch] city_range_iterate cleanup |
From: |
"Marko Lindqvist" <marko.lindqvist@xxxxxxxxxxx> |
Date: |
Tue, 28 Sep 2004 11:09:01 -0700 |
Reply-to: |
rt@xxxxxxxxxxx |
<URL: http://rt.freeciv.org/Ticket/Display.html?id=10375 >
There seems to couple of small mistakes in city_range_iterate macro.
For current user they have no effect of any kind (macro expansion leads
to correct C code)
- Caz
diff -Nurd -X.diff_ignore freeciv/ai/aicity.c freeciv/ai/aicity.c
--- freeciv/ai/aicity.c 2004-09-28 17:59:02.921875000 +0300
+++ freeciv/ai/aicity.c 2004-09-28 20:42:17.250000000 +0300
@@ -57,15 +57,15 @@
* (city_here) that exist within a given city list. */
#define city_range_iterate(city_here, list, range, city) \
{ \
- Continent_id continent = map_get_continent(pcity->x, pcity->y); \
+ Continent_id continent = map_get_continent(city_here->x, city_here->y); \
city_list_iterate(list, city) { \
if ((range == EFR_CITY && city == city_here) \
- || (range == EFR_LOCAL && acity == city_here) \
+ || (range == EFR_LOCAL && city == city_here) \
|| (range == EFR_CONTINENT \
&& map_get_continent(city->x, city->y) == continent) \
|| (range == EFR_PLAYER)) {
#define city_range_iterate_end \
- } } } city_list_iterate_end;
+ } } city_list_iterate_end } ;
#define CITY_EMERGENCY(pcity) \
(pcity->shield_surplus < 0 || city_unhappy(pcity) \
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Freeciv-Dev] (PR#10375) [Patch] city_range_iterate cleanup,
Marko Lindqvist <=
|
|