Skip to content

Commit

Permalink
Fix visibility of symbols exported in error
Browse files Browse the repository at this point in the history
  • Loading branch information
rfm committed Jan 26, 2025
1 parent 9ef3e2f commit 524daa1
Show file tree
Hide file tree
Showing 6 changed files with 18 additions and 15 deletions.
18 changes: 10 additions & 8 deletions Source/NSKVOInternal.h
Original file line number Diff line number Diff line change
Expand Up @@ -44,13 +44,15 @@

/* This Key Value Observing Implementation is tied to libobjc2 */

#import <Foundation/NSObject.h>
#import <Foundation/NSString.h>
#import <Foundation/NSDictionary.h>
#import <Foundation/NSArray.h>
#import <Foundation/NSSet.h>
#import <Foundation/NSKeyValueObserving.h>
#import <Foundation/NSException.h>
#import "Foundation/NSObject.h"
#import "Foundation/NSString.h"
#import "Foundation/NSDictionary.h"
#import "Foundation/NSArray.h"
#import "Foundation/NSSet.h"
#import "Foundation/NSKeyValueObserving.h"
#import "Foundation/NSException.h"

#import "GSPrivate.h"

#if defined(__OBJC2__)

Expand Down Expand Up @@ -114,7 +116,7 @@

// From NSKVOSwizzling
void
_NSKVOEnsureKeyWillNotify(id object, NSString *key);
_NSKVOEnsureKeyWillNotify(id object, NSString *key) GS_ATTRIB_PRIVATE;

#endif

Expand Down
2 changes: 1 addition & 1 deletion Source/NSKVOSupport.m
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ This code is licensed under the MIT License (MIT).

typedef void (^DispatchChangeBlock)(_NSKVOKeyObserver *);

NSString *
static NSString *
_NSKVCSplitKeypath(NSString *keyPath, NSString *__autoreleasing *pRemainder)
{
NSRange result = [keyPath rangeOfString:@"."];
Expand Down
4 changes: 2 additions & 2 deletions Source/NSKVOSwizzling.m
Original file line number Diff line number Diff line change
Expand Up @@ -476,7 +476,7 @@ static void funcName(id self, SEL _cmd, type val) \
break; \
}

SEL
static SEL
KVCSetterForPropertyName(NSObject *self, const char *key)
{
SEL sel = nil;
Expand Down Expand Up @@ -649,7 +649,7 @@ static void funcName(id self, SEL _cmd, type val) \
}
}

char *
static char *
mutableBufferFromString(NSString *string)
{
NSUInteger lengthInBytes = [string length] + 1;
Expand Down
3 changes: 2 additions & 1 deletion Source/NSKeyValueCoding+Caching.h
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@
*/

#import "Foundation/NSString.h"
#import "GSPrivate.h"

id
valueForKeyWithCaching(id obj, NSString *aKey);
valueForKeyWithCaching(id obj, NSString *aKey) GS_ATTRIB_PRIVATE;
2 changes: 1 addition & 1 deletion Source/NSKeyValueCoding+Caching.m
Original file line number Diff line number Diff line change
Expand Up @@ -426,7 +426,7 @@ static id _fnname(struct _KVCCacheSlot *slot, id obj) \
// resolveInstanceMethod:].
//
// objc_slot2 has the same struct layout as objc_method.
Method _Nullable _class_getMethodRecursive(Class aClass, SEL aSelector,
static Method _Nullable _class_getMethodRecursive(Class aClass, SEL aSelector,
uint64_t *version)
{
struct objc_slot2 *slot;
Expand Down
4 changes: 2 additions & 2 deletions Source/NSURLSessionTask.m
Original file line number Diff line number Diff line change
Expand Up @@ -303,7 +303,7 @@ @interface _GSMutableInsensitiveDictionary : NSMutableDictionary
*
* libcurl does not unfold HTTP "folded headers" (deprecated since RFC 7230).
*/
size_t
static size_t
header_callback(char *ptr, size_t size, size_t nitems, void *userdata)
{
NSURLSessionTask *task;
Expand Down Expand Up @@ -689,7 +689,7 @@ @interface _GSMutableInsensitiveDictionary : NSMutableDictionary
} /* header_callback */

/* CURLOPT_READFUNCTION: read callback for data uploads */
size_t
static size_t
read_callback(char *buffer, size_t size, size_t nitems, void *userdata)
{
NSURLSession *session;
Expand Down

0 comments on commit 524daa1

Please sign in to comment.