104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
|
id old = *ptr;
switch (copy) {
case 0:
*ptr = [value retain];
break;
case 2:
/*
* Apple uses this to indicate that the copy should be mutable.
* Please hit them for abusing a poor BOOL!
*/
*ptr = [value mutableCopy];
break;
default:
*ptr = [value copy];
}
[old release];
|
<
<
<
<
|
104
105
106
107
108
109
110
111
112
113
114
115
116
117
|
id old = *ptr;
switch (copy) {
case 0:
*ptr = [value retain];
break;
case 2:
*ptr = [value mutableCopy];
break;
default:
*ptr = [value copy];
}
[old release];
|