Skip to content

Commit 3624e0f

Browse files
committed
Fix ambiguous method (initWithObjects:count:) compilation errors under Clang 3.0.
1 parent c2146ff commit 3624e0f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

JSONKit.m

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -805,13 +805,13 @@ - (void)replaceObjectAtIndex:(NSUInteger)objectIndex withObject:(id)anObject
805805
- (id)copyWithZone:(NSZone *)zone
806806
{
807807
NSParameterAssert((objects != NULL) && (count <= capacity));
808-
return((mutations == 0UL) ? [self retain] : [[NSArray allocWithZone:zone] initWithObjects:objects count:count]);
808+
return((mutations == 0UL) ? [self retain] : [(NSArray *)[NSArray allocWithZone:zone] initWithObjects:objects count:count]);
809809
}
810810

811811
- (id)mutableCopyWithZone:(NSZone *)zone
812812
{
813813
NSParameterAssert((objects != NULL) && (count <= capacity));
814-
return([[NSMutableArray allocWithZone:zone] initWithObjects:objects count:count]);
814+
return([(NSMutableArray *)[NSMutableArray allocWithZone:zone] initWithObjects:objects count:count]);
815815
}
816816

817817
@end

0 commit comments

Comments
 (0)