Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Sources/CoreFoundation/CFBase.c
Original file line number Diff line number Diff line change
Expand Up @@ -790,7 +790,7 @@ void *__CFSafelyReallocateWithAllocator(CFAllocatorRef allocator, void *destinat
return _CLANG_ANALYZER_IGNORE_NONNULL(reallocated);;
}

Boolean __CFAllocatorRespectsHintZeroWhenAllocating(CFAllocatorRef allocator) {
CF_PRIVATE Boolean __CFAllocatorRespectsHintZeroWhenAllocating(CFAllocatorRef allocator) {
return allocator == kCFAllocatorSystemDefault || allocator == kCFAllocatorMallocZone;
}

Expand Down
1 change: 0 additions & 1 deletion Sources/CoreFoundation/include/ForFoundationOnly.h
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,6 @@ CF_EXPORT void *_Nonnull __CFSafelyReallocate(void * _Nullable destination, size
CF_EXPORT void *_Nonnull __CFSafelyReallocateWithAllocator(CFAllocatorRef _Nullable, void * _Nullable destination, size_t newCapacity, CFOptionFlags options, void (^_Nullable reallocationFailureHandler)(void *_Nonnull original, bool *_Nonnull outRecovered));
#endif

Boolean __CFAllocatorRespectsHintZeroWhenAllocating(CFAllocatorRef _Nullable allocator);
typedef CF_ENUM(CFOptionFlags, _CFAllocatorHint) {
_CFAllocatorHintZeroWhenAllocating = 1
};
Expand Down
2 changes: 0 additions & 2 deletions Sources/CoreFoundation/include/ForSwiftFoundationOnly.h
Original file line number Diff line number Diff line change
Expand Up @@ -105,8 +105,6 @@

_CF_EXPORT_SCOPE_BEGIN

CF_PRIVATE Boolean __CFAllocatorRespectsHintZeroWhenAllocating(CFAllocatorRef _Nullable allocator);

struct __CFSwiftObject {
uintptr_t isa;
};
Expand Down
2 changes: 2 additions & 0 deletions Sources/CoreFoundation/internalInclude/CFInternal.h
Original file line number Diff line number Diff line change
Expand Up @@ -1057,6 +1057,8 @@ CF_INLINE CFAllocatorRef __CFGetAllocator(CFTypeRef cf) { // !!! Use with CF typ
return *(CFAllocatorRef *)((char *)cf - 16);
}

CF_PRIVATE Boolean __CFAllocatorRespectsHintZeroWhenAllocating(CFAllocatorRef allocator);

/* !!! Avoid #importing objc.h; e.g. converting this to a .m file */
struct __objcFastEnumerationStateEquivalent {
unsigned long state;
Expand Down