title: How to assign a variable inside a block to a variable outside a block in objective-c
body: <p>Refer to <a href="https://stackoverflow.com/questions/7962721/how-to-assign-a-variable-inside-a-block-to-a-variable-outside-a-block">Assign a variable inside a Block to a variable outside a Block</a><br>
  It says it should add <code>__block</code> to the variable, but I see some codes in Google Youtube sample code for objc here <a href="https://code.google.com/p/google-api-objectivec-client/source/browse/trunk/Examples/YouTubeSample/YouTubeSampleWindowController.m" rel="nofollow noreferrer">https://code.google.com/p/google-api-objectivec-client/source/browse/trunk/Examples/YouTubeSample/YouTubeSampleWindowController.m</a>
  from line 279 to 290: </p>
  
  <pre><code>_channelListTicket = [service executeQuery:query
                      completionHandler:^(GTLServiceTicket *ticket,
                                          GTLYouTubeChannelListResponse *channelList,
                                          NSError *error) {
  // Callback
  
  // The contentDetails of the response has the playlists available for
  // "my channel".
  if ([[channelList items] count] &gt; 0) {
    GTLYouTubeChannel *channel = channelList[0];
    _myPlaylists = channel.contentDetails.relatedPlaylists;
  }
  </code></pre>
  
  <p>Why the variable <code>_myPlaylists</code> can be assigned without adding <code>__blocks</code> first ?</p>