• 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: More Xcode 7 inconsistency?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: More Xcode 7 inconsistency?


  • Subject: Re: More Xcode 7 inconsistency?
  • From: David Duncan <email@hidden>
  • Date: Wed, 14 Oct 2015 16:51:10 -0700

> On Oct 14, 2015, at 4:36 PM, Shane Stanley <email@hidden> wrote:
>
> On 15 Oct 2015, at 4:02 AM, David Duncan <email@hidden> wrote:
>>
>> The helpful followup is that it is generally encouraged to use empty containers (@[] or @{}) over nil when there is no semantic difference, as is the case for the aforementioned API.
>
> OK, but the docs still say: "The dictionary contains values from Document Types and must at least contain NSDocumentTypeDocumentAttribute." That suggests to me that an empty dictionary is not allowed.

I can’t speak for either the documentation or the implementation in this case, but I think the reasonable conclusion to make here is that either nil is allowed, or an empty dictionary is allowed, despite the documentation basically saying that both are disallowed, otherwise you cannot maintain the same API contract as was previously available.

I understand thats not a terribly satisfying answer, but given the direction I would suspect an empty dictionary is perfectly fine in this case.

--
David Duncan


_______________________________________________

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: 
 >More Xcode 7 inconsistency? (From: Graham Cox <email@hidden>)
 >Re: More Xcode 7 inconsistency? (From: Shane Stanley <email@hidden>)
 >Re: More Xcode 7 inconsistency? (From: Charles Srstka <email@hidden>)
 >Re: More Xcode 7 inconsistency? (From: David Duncan <email@hidden>)
 >Re: More Xcode 7 inconsistency? (From: Shane Stanley <email@hidden>)

  • Prev by Date: Re: More Xcode 7 inconsistency?
  • Next by Date: Re: More Xcode 7 inconsistency?
  • Previous by thread: Re: More Xcode 7 inconsistency?
  • Next by thread: Re: More Xcode 7 inconsistency?
  • Index(es):
    • Date
    • Thread