Skip to content

Commit c494f8d

Browse files
committed
Surpress "multiple methods named" error
I realize that `collection` won't always be an NSArray, but the cast will let the compiler know to expect a NSUInteger return type instead of `size_t` which is also a return type a method named `count` inside of JSONKit.
1 parent c2ef692 commit c494f8d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

JSONKit.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -848,7 +848,7 @@ - (void)dealloc
848848
- (NSArray *)allObjects
849849
{
850850
NSParameterAssert(collection != NULL);
851-
NSUInteger count = [collection count], atObject = 0UL;
851+
NSUInteger count = [(NSArray *)collection count], atObject = 0UL;
852852
id objects[count];
853853

854854
while((objects[atObject] = [self nextObject]) != NULL) { NSParameterAssert(atObject < count); atObject++; }

0 commit comments

Comments
 (0)