[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [gnugo-devel] libboard and board.h
From: |
Arend Bayer |
Subject: |
Re: [gnugo-devel] libboard and board.h |
Date: |
Wed, 6 Aug 2003 00:03:17 +0200 (CEST) |
On Tue, 5 Aug 2003, Gunnar Farneback wrote:
> Arend wrote:
> > The so-called board library is a separate layer independant of the
> > engine. It consists of the code of board.c, globals.c, hash.c,
> > printutils.c, sgffile.c, showbord.c.
> >
> > At the moment, it is forced at link time that this remains separate
> > (otherwise, patterns/joseki doesn't link). What I suggest to do is to force
> > this at compile: Instead of including liberty.h, these files should
> > include a new header file board.h. This should declare all public
> > functions of these 5 files. liberty.h will then include board.h.
> >
> > This should make these layers more transparent (I was pretty
> > confused when I stumble over the enforcement at link time). Also, if
> > someone wanted to use the board library in his own program, he would
> > have a clear-defined interface by including board.h.
> >
> > Objections?
>
> It's fine with me. However, you also need, or at least should, split
> off (or move into board.c) the board relevant parts of globals.c.
I've made this change and posted a revised version of my patch as
arend_5_1.2a. It contains both the above change and the introduction
of defs.h. If someonce can voice an opinion on the latter, as this might
be a matter of taste, this would be welcome.
(In short: The main advantage I see is defining e.g. dragon status'
_and_ their names _and_ the number of dragon status' (for array sizes)
at one places. I hope it's not too much preprocessor magic.)
Arend
- [gnugo-devel] libboard and board.h, Arend Bayer, 2003/08/03
- Re: [gnugo-devel] libboard and board.h, Inge Wallin, 2003/08/03
- Re: [gnugo-devel] libboard and board.h, Gunnar Farneback, 2003/08/05
- Re: [gnugo-devel] libboard and board.h,
Arend Bayer <=
- Re: [gnugo-devel] libboard and board.h, Gunnar Farneback, 2003/08/06
- Re: [gnugo-devel] libboard and board.h, Arend Bayer, 2003/08/07
- Re: [gnugo-devel] libboard and board.h, Arend Bayer, 2003/08/09
- Re: [gnugo-devel] libboard and board.h, Arend Bayer, 2003/08/10
- Re: [gnugo-devel] libboard and board.h, Arend Bayer, 2003/08/10
- Re: [gnugo-devel] libboard and board.h, SP LEE, 2003/08/20
- Re: [gnugo-devel] libboard and board.h, Gunnar Farneback, 2003/08/23