mirror of
https://github.com/gnustep/libs-base.git
synced 2025-06-01 09:02:01 +00:00
Change id* -> id[] for OS X 10.7 compatibility in NSArray. This change is required for ARC: now, id* means pointer to a single object, id[] means array.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33607 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
d22b0c4ff6
commit
b5b216f2be
3 changed files with 17 additions and 17 deletions
|
@ -271,7 +271,7 @@ static SEL rlSel;
|
|||
* Returns an autoreleased array containing the specified
|
||||
* objects, preserving order.
|
||||
*/
|
||||
+ (id) arrayWithObjects: (id*)objects count: (NSUInteger)count
|
||||
+ (id) arrayWithObjects: (const id[])objects count: (NSUInteger)count
|
||||
{
|
||||
return AUTORELEASE([[self allocWithZone: NSDefaultMallocZone()]
|
||||
initWithObjects: objects count: count]);
|
||||
|
@ -479,7 +479,7 @@ static SEL rlSel;
|
|||
* Copies the objects from the receiver to aBuffer, which must be
|
||||
* an area of memory large enough to hold them.
|
||||
*/
|
||||
- (void) getObjects: (id*)aBuffer
|
||||
- (void) getObjects: (id[])aBuffer
|
||||
{
|
||||
unsigned i, c = [self count];
|
||||
IMP get = [self methodForSelector: oaiSel];
|
||||
|
@ -492,7 +492,7 @@ static SEL rlSel;
|
|||
* Copies the objects from the range aRange of the receiver to aBuffer,
|
||||
* which must be an area of memory large enough to hold them.
|
||||
*/
|
||||
- (void) getObjects: (id*)aBuffer range: (NSRange)aRange
|
||||
- (void) getObjects: (id[])aBuffer range: (NSRange)aRange
|
||||
{
|
||||
unsigned i, j = 0, c = [self count], e = aRange.location + aRange.length;
|
||||
IMP get = [self methodForSelector: oaiSel];
|
||||
|
@ -879,7 +879,7 @@ static SEL rlSel;
|
|||
* and needs to be re-implemented in subclasses in order to have all
|
||||
* other initialisers work.
|
||||
*/
|
||||
- (id) initWithObjects: (id*)objects count: (NSUInteger)count
|
||||
- (id) initWithObjects: (const id[])objects count: (NSUInteger)count
|
||||
{
|
||||
self = [self init];
|
||||
return self;
|
||||
|
@ -1949,7 +1949,7 @@ compare(id elem1, id elem2, void* context)
|
|||
/**
|
||||
* Override our superclass's designated initializer to go our's
|
||||
*/
|
||||
- (id) initWithObjects: (id*)objects count: (NSUInteger)count
|
||||
- (id) initWithObjects: (const id[])objects count: (NSUInteger)count
|
||||
{
|
||||
self = [self initWithCapacity: count];
|
||||
if (count > 0)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue