Complete.Org: Mailing Lists: Archives: freeciv-dev: May 2004:
[Freeciv-Dev] (PR#8783) Re: Re: Freeciv commit: per: Look for informatio
Home

[Freeciv-Dev] (PR#8783) Re: Re: Freeciv commit: per: Look for informatio

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: undisclosed-recipients: ;
Subject: [Freeciv-Dev] (PR#8783) Re: Re: Freeciv commit: per: Look for information in savegames about where n...
From: "Jason Short" <jdorje@xxxxxxxxxxxxxxxxxxxxx>
Date: Wed, 19 May 2004 17:18:23 -0700
Reply-to: rt@xxxxxxxxxxx

<URL: http://rt.freeciv.org/Ticket/Display.html?id=8783 >

Raimar Falke wrote:

>>+#define NO_START_POS -1
> 
> 
> Why is this needed? Why can't another bool array be used? Why not a
> const with function scope? And when a define is used why isn't this
> undefined after the function?

This patch makes it a const int.

jason

? eff
? flags
? data/flags
Index: server/gamehand.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/server/gamehand.c,v
retrieving revision 1.133
diff -u -r1.133 gamehand.c
--- server/gamehand.c   19 May 2004 20:11:17 -0000      1.133
+++ server/gamehand.c   20 May 2004 00:17:53 -0000
@@ -95,7 +95,7 @@
 ****************************************************************************/
 void init_new_game(void)
 {
-#define NO_START_POS -1
+  const int NO_START_POS = -1;
   int start_pos[game.nplayers];
   bool pos_used[map.num_start_positions];
   int i, num_used = 0;

[Prev in Thread] Current Thread [Next in Thread]
  • [Freeciv-Dev] (PR#8783) Re: Re: Freeciv commit: per: Look for information in savegames about where n..., Jason Short <=