Re: CGFloat and 64 Bit
Re: CGFloat and 64 Bit
- Subject: Re: CGFloat and 64 Bit
- From: Rob Keniger <email@hidden>
- Date: Mon, 9 Feb 2009 15:37:54 +1000
On 08/02/2009, at 9:52 PM, Gerriet M. Denkmann wrote:
When I build a Cocoa Project with 32/64 bit, this line gets a warning:
NSSize a = NSMakeSize( 11.2, 22.4);
which went away using:
NSSize a = NSMakeSize( (CGFloat)11.2, (CGFloat)22.4);
Is this the only and correct way to use NSMakeSize() ? Looks kind of
ugly.
Try this:
NSSize a = NSMakeSize( 11.2f, 22.4f);
The "f" suffix is a hint to the compiler that it's a float value.
--
Rob Keniger
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden