• 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: Annoying compiler warnings (repost)
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Annoying compiler warnings (repost)


  • Subject: Re: Annoying compiler warnings (repost)
  • From: Rob Rix <email@hidden>
  • Date: Tue, 4 Sep 2001 22:46:01 -0400

This is very definitely a nonsense. A header can NEVER EVER have this
result(*): even if it contains "unresolved" declarations, they would not
cause link problems when not actually used.

The problem would be elsewhere: you _CAN_ import _ANY_ header, and all will
work properly. The @class directive is needed for cross-refs only (when class
A refs class B, which refs class A, so that you can't just import A.h to B.h
and B.h to A.h for obvious reasons).

Well, just thought I'd let everybody know that I cleared up my "nonsense" with a bit of help from these e-mails.

There weren't any cross-references present, all that was happening was that me, being the fool that I am, decided to import a header with functions I'd created from within one of my class' header file. So, the link error was telling me that there were multiple definitions of a symbol.

Well, it all makes sense now, but still, none of this #import stuff is very clear to me. Thankfully, I now have some guidelines I can follow, which makes it just a wee bit clearer.

Special thanks go to Ondra who didn't believe that what happened could have happened :)

-- Rob

TINRA - There Is No Right Answer


  • Prev by Date: Re: Installing OmniFrameworks
  • Next by Date: Re: Math question
  • Previous by thread: Re: Annoying compiler warnings (repost)
  • Next by thread: Re: launchApplication
  • Index(es):
    • Date
    • Thread