title: NSMapTable releases entry before keys deallocates
body: <p>I have some confusion using <code>NSMapTable</code>.</p>
  
  <p>I have <code>NSMapTable</code> with <code>NSPointerFunctionsWeakMemory</code>:</p>
  
  <pre><code>    _controllersTable = [[NSMapTable alloc] initWithKeyOptions:NSPointerFunctionsWeakMemory|NSPointerFunctionsObjectPointerPersonality
                                                    valueOptions:NSPointerFunctionsWeakMemory|NSPointerFunctionsObjectPointerPersonality
                                                        capacity:0];
  </code></pre>
  
  <p>Assume I create <code>UIViewController</code> and add it to MapTable:</p>
  
  <pre><code>MyVC *myVC = [[MyVC alloc] init];
  [self.controllersTable setObject:@1 forKey:controller]
  </code></pre>
  
  <p><strong>MyVC.m</strong> </p>
  
  <pre><code>- (void)dealloc {
  
      // [[[controllersTable keyEnumerator] allObjects] count]] == 0
  
  }
  </code></pre>
  
  <p>So, by the time MyVC calls dealloc, there is not entry for that VC. Are there any way to get value from <code>NSMapTable</code> in that case?</p>
  
  <p><strong>PS</strong></p>
  
  <p>I can't use <code>NSPointerFunctionsStrongMemory</code> for storing keys, because it can introduce retain cycle.</p>