Complete.Org: Mailing Lists: Archives: freeciv-dev: October 2002:
[Freeciv-Dev] Re: [Patch] Change MAPSTEP macro (PR#2123)
Home

[Freeciv-Dev] Re: [Patch] Change MAPSTEP macro (PR#2123)

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: Gregory Berkolaiko <Gregory.Berkolaiko@xxxxxxxxxxxx>
Cc: Jason Short <jdorje@xxxxxxxxxxxxxxxxxxxxx>, Freeciv Development List <freeciv-dev@xxxxxxxxxxx>
Subject: [Freeciv-Dev] Re: [Patch] Change MAPSTEP macro (PR#2123)
From: rf13@xxxxxxxxxxxxxxxxx
Date: Mon, 7 Oct 2002 03:33:25 -0700

On Fri, Oct 04, 2002 at 04:50:59PM +0100, Gregory Berkolaiko wrote:
> On Fri, 4 Oct 2002 rf13@xxxxxxxxxxxxxxxxx wrote:
> 
> > On Fri, Oct 04, 2002 at 01:05:57PM +0100, Gregory Berkolaiko wrote:
> > 
> > > I will just add an explaining comment to the patch and resubmit it.
> > 
> > something like: "we should use DIRSTEP here BUT we also want to use src
> > as dest so we do a direct access to the DIR_* arrays." would do the job.
> 
> Actually I didn't have this in mind :)
> 
> BTW, why do you think that DIRSTEP should be the only way to access DIR_* 
> arrays?
> 
> This is a purely theoretical question, of course.

In in ideal world there would be no global variables. Constants aren't
variables in this context. We have seen that constant arrays are also
bad because of the indexing problem. A function/macro also can do
bound checking.

        Raimar

-- 
 email: rf13@xxxxxxxxxxxxxxxxx


[Prev in Thread] Current Thread [Next in Thread]