Complete.Org: Mailing Lists: Archives: freeciv-dev: March 2002:
[Freeciv-Dev] Re: [Patch] Bool cleanup of client/
Home

[Freeciv-Dev] Re: [Patch] Bool cleanup of client/

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: "Per I. Mathisen" <Per.Inge.Mathisen@xxxxxxxxxxx>
Cc: freeciv development list <freeciv-dev@xxxxxxxxxxx>
Subject: [Freeciv-Dev] Re: [Patch] Bool cleanup of client/
From: Ben Webb <ben@xxxxxxxxxxxxxxxxxxxxxx>
Date: Fri, 15 Mar 2002 17:59:56 +0000

On Fri, Mar 15, 2002 at 06:41:02PM +0100, Per I. Mathisen wrote:
> On Fri, 15 Mar 2002, Raimar Falke wrote:
> >  - replaces gboolean with bool
> 
> Uh-huh, is this a good idea? If you define bool to a different size than
> the gnomes do, won't this possibly cause some very hard to find breakages?

        It seems strange to me, conceptually, to pass "bool"s to functions
that are prototyped to take "gboolean"s.

> So you have settled on char for bool? I think this is a bad idea. Modern
> CPUs don't like 8bit types much.

        In my opinion, if it's really going to make that much difference,
the change needs to be tested on as many architectures as possible, since
(as I seem to recall being pointed out already) whether "char" is faster
than "int" tends to be machine-specific. This would, presumably, require
a configure test, and this seems like a lot of work for something with a
possibly negligible performance improvement.

        Ben
-- 
ben@xxxxxxxxxxxxxxxxxxxxxx           http://bellatrix.pcl.ox.ac.uk/~ben/
"And the man with the golden gun thinks he knows so much"


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