• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: C again
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: C again


  • Subject: Re: C again
  • From: Angela Brett <email@hidden>
  • Date: Sun, 31 Aug 2003 13:41:25 +1200

while (((ch = PEEK (myFile)) != EOF) && (error = 0))

I think you mean (error==0)

error=0 is of course assigning 0 to error and returning 0. It's the sort of mistake anyone can make while programming at ridiculous hours of the morning (like 7am... who's together by then?) and/or drunk. :) In fact there have been some rather tedious discussions on the list recently about whether people should routinely write (0==error) so the compiler will catch such mistakes. I'm not going to comment on that in case it starts up again.

Now, back to lurking and not having time to read many posts.
--
Angela Brett email@hidden http://macintosh.geek.nz
_______________________________________________
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.
References: 
 >C again (From: David Thorp <email@hidden>)

  • Prev by Date: Re: Enough with the newbie C questions!
  • Next by Date: Re: Enough with the newbie C questions!
  • Previous by thread: Re: C again
  • Next by thread: Any ~/Sites/ equivalent of NSDocumentDirectory?
  • Index(es):
    • Date
    • Thread