• 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
Odd NSDictionary Problem
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Odd NSDictionary Problem


  • Subject: Odd NSDictionary Problem
  • From: email@hidden
  • Date: Wed, 23 Jul 2003 01:26:48 -0400

Hello,

I have an odd (or maybe not so odd, I dunno) NSDictionary problem.

Ok, I have two NSMutableDictionarys.
During a 'for' loop, i do something like this:

-----------------------------------------------------
[dictionaryOne setObject:A forKey:B];
[dictionaryTwo setObject:B forKey:A];

int x = [dictionaryOne count];
int y = [dictionaryTwo count];
----------------------------------------------------

Object A and B change every loop. When I look at the counts of both dictionaries, they are not the same. One dictionary has 2 more entries than the other. Shouldn't they both come out the same?

-Alex P.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

  • Follow-Ups:
    • Re: Odd NSDictionary Problem
      • From: Christopher Corbell <email@hidden>
  • Prev by Date: Re: Bug reports and documentation updates (was Re: Subclassing NSPort (or NSSocketPort))
  • Next by Date: Re: Design for Cocoa (was Re: Can a subclass of NSDictionary do this?)
  • Previous by thread: NSMatrix overhead
  • Next by thread: Re: Odd NSDictionary Problem
  • Index(es):
    • Date
    • Thread