38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
|
id old = *ptr;
switch (copy) {
case 0:
*ptr = [value retain];
break;
case 2:
*ptr = [value mutableCopy];
break;
default:
*ptr = [value copy];
}
[old release];
}
}
id *ptr = (id*)((char*)self + offset);
id old = *ptr;
switch (copy) {
case 0:
*ptr = [value retain];
break;
case 2:
*ptr = [value mutableCopy];
break;
default:
*ptr = [value copy];
}
[old release];
}
|
>
>
>
>
>
>
>
>
>
>
>
>
>
|
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
|
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];
return;
}
}
id *ptr = (id*)((char*)self + offset);
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];
}
|