Fix implicit-function-declaration

This commit is contained in:
Thomas A 2023-06-19 11:36:44 -07:00
parent db263d6dd6
commit b16f3de95c
8 changed files with 23 additions and 1 deletions

View File

@ -31,6 +31,7 @@
#include <CoreFoundation/CFRuntime.h>
#include "CFInternal.h"
#include "CFBasicHash.h"
#include "FoundationExceptions.h"
#include <string.h>
#include <stdlib.h>
#include <stdio.h>

6
CFSortFunctions.h Normal file
View File

@ -0,0 +1,6 @@
#ifndef CF_SORT_FUNCTIONS_H
#define CF_SORT_FUNCTIONS_H
void CFSortIndexes(CFIndex *indexBuffer, CFIndex count, CFOptionFlags opts, CFComparisonResult (^cmp)(CFIndex, CFIndex));
#endif // CF_SORT_FUNCTIONS_H

View File

@ -44,7 +44,15 @@
#include <stdio.h>
#include <stdlib.h>
#include <pwd.h>
//#include <NSSystemDirectories.h>
// Can't include <NSSystemDirectories.h> due to type conflict with NSSearchPathDirectory
// #ifndef __NS_SYSTEM_DIRECTORIES_H__
// #define __NS_SYSTEM_DIRECTORIES_H__
typedef unsigned int NSSearchPathEnumerationState;
__OSX_AVAILABLE_STARTING(__MAC_10_0,__IPHONE_2_0)
extern NSSearchPathEnumerationState NSGetNextSearchPathEnumeration(NSSearchPathEnumerationState state, char *path);
__OSX_AVAILABLE_STARTING(__MAC_10_0,__IPHONE_2_0)
extern NSSearchPathEnumerationState NSStartSearchPathEnumeration(NSSearchPathDirectory dir, NSSearchPathDomainMask domainMask);
// #endif /* __NS_SYSTEM_DIRECTORIES_H__ */
CFSearchPathEnumerationState __CFStartSearchPathEnumeration(CFSearchPathDirectory dir, CFSearchPathDomainMask domainMask) {
return NSStartSearchPathEnumeration(dir, domainMask);

View File

@ -18,6 +18,7 @@
#import "NSObjectInternal.h"
#import "NSStringInternal.h"
#import "CFInternal.h"
#import "CFSortFunctions.h"
CF_EXPORT Boolean _CFArrayIsMutable(CFArrayRef array);
CF_EXPORT NSUInteger _CFArrayFastEnumeration(CFArrayRef array, NSFastEnumerationState *state, id __unsafe_unretained stackbuffer[], NSUInteger count);

View File

@ -15,6 +15,7 @@
#include <Foundation/NSError.h>
#import "CFInternal.h"
#import "CFSortFunctions.h"
#import "NSFastEnumerationEnumerator.h"
#import <Foundation/NSKeyValueObserving.h>
#import "NSObjectInternal.h"

View File

@ -23,6 +23,7 @@ along with Darling. If not, see <http://www.gnu.org/licenses/>.
// Copyright (c) 2014 Apportable. All rights reserved.
//
#import <CoreFoundation/CFLogUtilities.h>
#import <Foundation/NSInvocation.h>
#import <Foundation/NSMethodSignature.h>

View File

@ -13,9 +13,12 @@
#import <Foundation/NSIndexSet.h>
#import <Foundation/NSLocale.h>
#import <objc/message.h>
#import "CFBasicHash.h"
#import "ForFoundationOnly.h"
#import "CFSortFunctions.h"
#import "NSBasicHash.h"
#import "NSFastEnumerationEnumerator.h"
#import "NSObjectInternal.h"

View File

@ -844,6 +844,7 @@ CF_INLINE dispatch_queue_t __CFDispatchQueueGetGenericBackground(void) {
#endif
CF_PRIVATE void __CFAttributedStringInitialize(void);
CF_EXTERN_C_END