Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
WWDC 2012 のコア データのベスト プラクティスのビデオで、彼は performBlockAndWait: には自動解放プールが含まれていないと述べています。(一方、performBlock: は行います)
なぜだめですか?これの結果は正確には何ですか?ブロックの内容を自動解放プールにラップする必要がありますか - すべてのアップルの例はこれを行いません。または、 performBlock: と対比するという彼のポイントでした。これには必要ありません。
バンデジャパイサ、
-performBlockAndWait: 周囲の自動解放プールの恩恵を受けます。(-performBlockAndWait: 現在のスレッドで直接実行されるように見えます。) したがって、独自の自動解放プールは必要ありません。
アンドリュー