mirror of
https://github.com/gnustep/libs-base.git
synced 2025-05-21 12:41:19 +00:00
More tweaks for garbage collection mode, including making NSNotificationCenter use weak pointers (things are never removed if it uses strong pointers because they remove themselves in the -dealloc method, which is never called, and can't remove themselves in the -finalize method because the -finalize method would not be called until after they have been removed - this is consistent with Apple behaviour).
Gorm now works correctly when built with GC enabled. git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33109 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
a439972605
commit
b08b2d0f34
7 changed files with 20 additions and 26 deletions
|
@ -142,7 +142,7 @@ struct NCTbl; /* Notification Center Table structure */
|
|||
*/
|
||||
|
||||
typedef struct Obs {
|
||||
id observer; /* Object to receive message. */
|
||||
__weak id observer; /* Object to receive message. */
|
||||
SEL selector; /* Method selector. */
|
||||
IMP method; /* Method implementation. */
|
||||
struct Obs *next; /* Next item in linked list. */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue