Author: rfm Date: Fri Jul 15 12:07:50 2016 New Revision: 39997 URL: http://svn.gna.org/viewcvs/gnustep?rev=39997&view=rev Log: tidy
Modified: libs/base/trunk/Source/NSSortDescriptor.m Modified: libs/base/trunk/Source/NSSortDescriptor.m URL: http://svn.gna.org/viewcvs/gnustep/libs/base/trunk/Source/NSSortDescriptor.m?rev=39997&r1=39996&r2=39997&view=diff ============================================================================== --- libs/base/trunk/Source/NSSortDescriptor.m (original) +++ libs/base/trunk/Source/NSSortDescriptor.m Fri Jul 15 12:07:50 2016 @@ -126,16 +126,16 @@ + (id) sortDescriptorWithKey: (NSString *)aKey ascending: (BOOL)ascending { - return AUTORELEASE([[self alloc] initWithKey: aKey ascending: ascending]); + return AUTORELEASE([[self alloc] initWithKey: aKey ascending: ascending]); } + (id) sortDescriptorWithKey: (NSString *)aKey ascending: (BOOL)ascending selector: (SEL)aSelector { - return AUTORELEASE([[self alloc] initWithKey: aKey - ascending: ascending - selector: aSelector]); + return AUTORELEASE([[self alloc] initWithKey: aKey + ascending: ascending + selector: aSelector]); } - (id) initWithKey: (NSString *) key ascending: (BOOL) ascending @@ -347,7 +347,7 @@ @implementation NSArray (NSSortDescriptorSorting) -- (NSArray *) sortedArrayUsingDescriptors: (NSArray *) sortDescriptors +- (NSArray *) sortedArrayUsingDescriptors: (NSArray *)sortDescriptors { NSMutableArray *sortedArray = [GSMutableArray arrayWithArray: self]; @@ -364,19 +364,19 @@ */ static void SortRange(id *objects, NSRange range, id *descriptors, - unsigned numDescriptors) + NSUInteger numDescriptors) { NSSortDescriptor *sd = (NSSortDescriptor*)descriptors[0]; GSSortUnstable(objects, range, sd, GSComparisonTypeSortDescriptor, NULL); if (numDescriptors > 1) { - unsigned start = range.location; - unsigned finish = NSMaxRange(range); + NSUInteger start = range.location; + NSUInteger finish = NSMaxRange(range); while (start < finish) { - unsigned pos = start + 1; + NSUInteger pos = start + 1; /* Find next range of adjacent objects. */ @@ -403,8 +403,8 @@ - (void) sortUsingDescriptors: (NSArray *)sortDescriptors { - unsigned count = [self count]; - unsigned numDescriptors = [sortDescriptors count]; + NSUInteger count = [self count]; + NSUInteger numDescriptors = [sortDescriptors count]; if (count > 1 && numDescriptors > 0) { @@ -415,7 +415,7 @@ [self getObjects: objects]; if ([sortDescriptors isProxy]) { - unsigned i; + NSUInteger i; for (i = 0; i < numDescriptors; i++) { @@ -440,7 +440,7 @@ - (void) sortUsingDescriptors: (NSArray *)sortDescriptors { - unsigned dCount = [sortDescriptors count]; + NSUInteger dCount = [sortDescriptors count]; if (_count > 1 && dCount > 0) { @@ -448,7 +448,7 @@ if ([sortDescriptors isProxy]) { - unsigned i; + NSUInteger i; for (i = 0; i < dCount; i++) { _______________________________________________ Gnustep-cvs mailing list Gnustep-cvs@gna.org https://mail.gna.org/listinfo/gnustep-cvs