Fixed ASSIGN macro from NSObject.h

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@3479 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Richard Frith-MacDonald 1998-12-17 11:11:22 +00:00
parent 9104a852b4
commit b824752830

View file

@ -65,15 +65,17 @@
#ifndef ASSIGN
#define ASSIGN(object,value) ({\
if (value != object) \
if (value) \
{ \
[value retain]; \
} \
if (object) \
{ \
[object release]; \
} \
object = value; \
{ \
if (value) \
{ \
[value retain]; \
} \
if (object) \
{ \
[object release]; \
} \
object = value; \
} \
})
#endif