mirror of
https://github.com/gnustep/libs-base.git
synced 2025-04-22 08:26:27 +00:00
(main): Removed several -autorelease calls that are repetative, now
that NSArray autoreleases properly. The test still does not complete successfully. It tries to send -cString to an NSMutableArray. git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@1387 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
cbcb4e387b
commit
64a214f8da
1 changed files with 3 additions and 2 deletions
|
@ -46,13 +46,13 @@ main()
|
|||
{
|
||||
// Instance methods for allocating and initializing an array
|
||||
printf("Method: -arrayByAddingObject:\n");
|
||||
d = [[c arrayByAddingObject: s] autorelease];
|
||||
d = [c arrayByAddingObject: s];
|
||||
printf("NSArray has count %d\n", [c count]);
|
||||
if ([d count] != 4)
|
||||
printf("Error: count != 4\n");
|
||||
|
||||
printf("Method: -arrayByAddingObjectsFromArray:\n");
|
||||
e = [[c arrayByAddingObjectsFromArray: b] autorelease];
|
||||
e = [c arrayByAddingObjectsFromArray: b];
|
||||
printf("NSArray has count %d\n", [c count]);
|
||||
if ([e count] != 4)
|
||||
printf("Error: count != 4\n");
|
||||
|
@ -168,6 +168,7 @@ main()
|
|||
f = [NSMutableArray arrayWithCapacity: 10];
|
||||
assert(f);
|
||||
f = [[NSMutableArray alloc] initWithCapacity: 10];
|
||||
[f release];
|
||||
assert(f);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue