Re: C question for you old guys ;-)
Re: C question for you old guys ;-)
- Subject: Re: C question for you old guys ;-)
- From: Dan Sugalski <email@hidden>
- Date: Mon, 9 Jun 2003 13:49:54 -0400
At 9:49 AM -0700 6/9/03, John C. Randolph wrote:
On Monday, June 9, 2003, at 05:43 AM, Dan Sugalski wrote:
It catches the times when I miss a = in the test--"NULL = foo"
throws a compile-time error, "foo = NULL" leads to a bughunt
session.
#define is ==
if (spriteInfo is NULL)
.. ever since I started doing this, I've never assigned when I meant
to compare.
When I do C things, I try hard not to warp the syntax of the language
like that. I have a hard enough time juggling three or four computer
languages at once--throwing in variants like that makes things too
confusing. (Not to mention the issues it has for maintenance
programmers later on)
--
Dan
--------------------------------------"it's like this"-------------------
Dan Sugalski even samurai
email@hidden have teddy bears and even
teddy bears get drunk
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.