• 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: Mysterious warning (comparison between pointer and integer)
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Mysterious warning (comparison between pointer and integer)


  • Subject: Re: Mysterious warning (comparison between pointer and integer)
  • From: Tommy Nordgren <email@hidden>
  • Date: Thu, 12 Jul 2007 12:10:34 +0200


On 12 jul 2007, at 11.52, Alastair Houghton wrote:

On 12 Jul 2007, at 10:19, Stephane Sudre wrote:

On 11 juil. 07, at 12:37, Alastair Houghton wrote:

I think, though I'm not certain, that you may be missing a

  #include <arpa/inet.h>

at the top of your file. The line you're getting a warning for expands to

Correct. With the addition of this header it's working fine. Thanks.

I don't really understand why gcc does not just state that the prototype is unknown.

Because that warning is not enabled by default using Xcode's default project templates. I tend to enable more warnings in projects I'm working on, just to avoid confusion like this; the only downside is that some of the potentially useful warnings trigger a lot for typical Objective-C code.


Kind regards,

Alastair.

I've done some tests. Warnings about missing prototypes are simply not shown, even if you enable all warnings in the target settings.
It appears necessary to compile files as Objective C++ instead of as Objective C, to catch missing function prototypes.
------------------------------------------------------
"Home is not where you are born, but where your heart finds peace" -
Tommy Nordgren, "The dying old crone"
email@hidden



_______________________________________________ Do not post admin requests to the list. They will be ignored. Xcode-users mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
  • Follow-Ups:
    • Re: Mysterious warning (comparison between pointer and integer)
      • From: Alastair Houghton <email@hidden>
References: 
 >Mysterious warning (comparison between pointer and integer) (From: Stéphane Sudre <email@hidden>)
 >Re: Mysterious warning (comparison between pointer and integer) (From: Alastair Houghton <email@hidden>)
 >Re: Mysterious warning (comparison between pointer and integer) (From: Stephane Sudre <email@hidden>)
 >Re: Mysterious warning (comparison between pointer and integer) (From: Alastair Houghton <email@hidden>)

  • Prev by Date: Re: Mysterious warning (comparison between pointer and integer)
  • Next by Date: Re: Mysterious warning (comparison between pointer and integer)
  • Previous by thread: Re: Mysterious warning (comparison between pointer and integer)
  • Next by thread: Re: Mysterious warning (comparison between pointer and integer)
  • Index(es):
    • Date
    • Thread