• 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: Help with recursive includes
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Help with recursive includes


  • Subject: Re: Help with recursive includes
  • From: Tommy Nordgren <email@hidden>
  • Date: Tue, 24 Feb 2009 00:34:50 +0100


On Feb 22, 2009, at 2:12 AM, Aaron Wallis wrote:

While that's always an option, it's not exactly the answer I was hoping to hear :D

The good news is I was able to recreate the file in a considerably smaller scale and have uploaded the source here: http://junk.isnot.tv/test.zip

As you can see, i've got two classes which include each others headers (since they need to call each others methods directly)
I may be breaking some design patterns by doing this, and if so, please point them out - cause they could be the cause of the problem :D
Are you importing the header files from each other? That's the problem. In one of the header files at least, you should
forward declare the class defined in the other header file like this:


@class SomeClass;

@interface MyClass: NSObject
{
	SomeClass * aMember;
}

This style will probably fix your problem if you applies it consistenly
------
What is a woman that you forsake her, and the hearth fire and the home acre,
to go with the old grey Widow Maker. --Kipling, harp song of the Dane women
Tommy Nordgren
email@hidden




_______________________________________________

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


References: 
 >Help with recursive includes (From: Aaron Wallis <email@hidden>)
 >Re: Help with recursive includes (From: Aaron Wallis <email@hidden>)

  • Prev by Date: Re: Moving oneself to /Applications (or ~/Applications)
  • Next by Date: Re: Moving oneself to /Applications (or ~/Applications)
  • Previous by thread: Re: Help with recursive includes
  • Next by thread: protocol vs. subclassing NSView
  • Index(es):
    • Date
    • Thread