• 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: Thoughts on Cocoa source code
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Thoughts on Cocoa source code


  • Subject: Re: Thoughts on Cocoa source code
  • From: Jens Alfke via Cocoa-dev <email@hidden>
  • Date: Wed, 9 Oct 2019 15:14:51 -0700


> On Oct 9, 2019, at 11:39 AM, Aandi Inston <email@hidden> wrote:
>
> * But for whatever reason, I'm using the Mac OS 10.14 SDK. So that will get a
> compile-time warning.

Only if you don't turn on -Werror, which I really, really recommend everyone
do. Calling a method that a class isn't declared as implementing is a fairly
common mistake, and warnings are way too easy to overlook.

In this situation, you get around the warning/error by declaring the method
yourself in a category on the framework class.

> * I add a check for actual OS version, so I am very sure not try to call
> [NSApplication doUsefulThing]
> unless the OS is 10.15 or later.
> * But what happens if it runs in 10.15? Does it actually do the useful thing?

The method will be called, yes. I can't think of any particular reason it
wouldn't work.

—Jens
_______________________________________________

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

  • Follow-Ups:
    • Re: Thoughts on Cocoa source code
      • From: Jean-Daniel via Cocoa-dev <email@hidden>
References: 
 >Thoughts on Cocoa source code (From: Turtle Creek Software via Cocoa-dev <email@hidden>)
 >Re: Thoughts on Cocoa source code (From: Jens Alfke via Cocoa-dev <email@hidden>)
 >Re: Thoughts on Cocoa source code (From: Aandi Inston via Cocoa-dev <email@hidden>)

  • Prev by Date: Re: Thoughts on Cocoa source code
  • Next by Date: Re: Thoughts on Cocoa source code
  • Previous by thread: Re: Thoughts on Cocoa source code
  • Next by thread: Re: Thoughts on Cocoa source code
  • Index(es):
    • Date
    • Thread