gnustep-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [RFC/Proposal] Cocoa.h header


From: Alexander Malmberg
Subject: Re: [RFC/Proposal] Cocoa.h header
Date: Mon, 22 Nov 2004 17:56:00 +0100
User-agent: Mozilla Thunderbird 0.8 (X11/20040926)

Fred Kiefer wrote:
Alexander Malmberg wrote:
[snip]
Well, fwiw, I think it's Wrong to put darwin system header compatibility stuff in Cocoa.h. If anyone is really interested in knowing why, I could make an attempt to explain. Otherwise, suffice to say that:

Not sure why you call the implicit inclusion of math.h in Foundation.h on Cocoa systems "darwin system header compatibility".

I haven't said anything about Foundation.h on Cocoa. I'm talking about core/gui/Headers/Cocoa/Cocoa.h, which (presumably), for compatibility reasons, includes symbols defined in darwin system headers that happen to be visible after including Cocoa.h on mosx, hence "darwin system header compatibility" stuff.

[snip]
3. If you insist on defining the symbols yourself, at least get the rounding right for M_PI.

This one falls back on you :-) I stole the definition from NSBezierPath, where PI instead of M_PI is used (which needs correction!), and if I remember correctly this was one of your first contributions to GNUstep years ago.

It is better to check cvs history than to try to remember. The definition of PI in NSBezierPath.m was added by Enrico Sersale 1999-12-21.

You only focused on the definition of M_PI, which shouldn't do to much harm as it is protected by an #ifdef. You didn't mention the other bit, which I see as being much more important, the handling of the compiler specific bool type. GNUstep will keep on supporting gcc releases where this type is not present, so we need to offer some sort of compatibility. What are your choices here?

I don't really have anything to add beyond what I already said in 1.; in short, "don't do that".

- Alexander Malmberg




reply via email to

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