static VALUE rb_set_clear(VALUE set, SEL sel) { rb_set_modify_check(set); CFSetRemoveAllValues((CFMutableSetRef)set); return set; }
static void __CFSetDeallocate(CFTypeRef cf) { CFMutableSetRef set = (CFMutableSetRef)cf; CFAllocatorRef allocator = __CFGetAllocator(set); if (__CFSetGetType(set) == __kCFSetImmutable) { __CFBitfieldSetValue(((CFRuntimeBase *)set)->_info, 1, 0, __kCFSetFixedMutable); } CFSetRemoveAllValues(set); if (__CFSetGetType(set) == __kCFSetMutable && set->_buckets) { CFAllocatorDeallocate(allocator, set->_buckets); } }