From ba7a9c0a8e974bd2ed0ccfe43768eb78d3e37f7b Mon Sep 17 00:00:00 2001 From: Frederik Seiffert Date: Wed, 10 Jul 2019 11:39:43 +0200 Subject: [PATCH] Fix NSArray and NSOrderedSet KVC method types to not use generic type. These methods set/return properties of the elements, not the elements themselves. --- ChangeLog | 7 +++++++ Headers/Foundation/NSArray.h | 4 ++-- Headers/Foundation/NSOrderedSet.h | 4 ++-- 3 files changed, 11 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index 05aceb764..5268d844e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2019-07-10 Frederik Seiffert + + * Headers/Foundation/NSArray.h: + * Headers/Foundation/NSOrderedSet.h: + Fix generics definition of NSMutableArray and NSMutableOrderedSet. + Fix NSArray and NSOrderedSet KVC method types to not use generic type. + 2019-07-02 Wolfgang Lux * Tests/base/GSTLS/basic.m: Use fixed time zone. diff --git a/Headers/Foundation/NSArray.h b/Headers/Foundation/NSArray.h index 2d8af0e1c..fd2ac011c 100644 --- a/Headers/Foundation/NSArray.h +++ b/Headers/Foundation/NSArray.h @@ -166,8 +166,8 @@ typedef NSUInteger NSBinarySearchingOptions; - (BOOL) writeToFile: (NSString*)path atomically: (BOOL)useAuxiliaryFile; #if OS_API_VERSION(GS_API_MACOSX, GS_API_LATEST) - (BOOL) writeToURL: (NSURL*)url atomically: (BOOL)useAuxiliaryFile; -- (GS_GENERIC_TYPE(ElementT)) valueForKey: (NSString*)key; -- (void) setValue: (GS_GENERIC_TYPE(ElementT))value forKey: (NSString*)key; +- (id) valueForKey: (NSString*)key; +- (void) setValue: (id)value forKey: (NSString*)key; #endif #if OS_API_VERSION(MAC_OS_X_VERSION_10_6, GS_API_LATEST) diff --git a/Headers/Foundation/NSOrderedSet.h b/Headers/Foundation/NSOrderedSet.h index 749bc1987..e63b6641c 100644 --- a/Headers/Foundation/NSOrderedSet.h +++ b/Headers/Foundation/NSOrderedSet.h @@ -125,8 +125,8 @@ extern "C" { range: (NSRange)aRange; // Key value coding support -- (void) setValue: (GS_GENERIC_TYPE(ElementT))value forKey: (NSString*)key; -- (GS_GENERIC_TYPE(ElementT)) valueForKey: (NSString*)key; +- (void) setValue: (id)value forKey: (NSString*)key; +- (id) valueForKey: (NSString*)key; // Comparing Sets - (BOOL) isEqualToOrderedSet: (NSOrderedSet *)aSet;