Lines Matching refs:intern

81 	zend_user_iterator  intern;  member
354 spl_heap_object *intern = spl_heap_from_obj(object); in spl_heap_object_free_storage() local
356 zend_object_std_dtor(&intern->std); in spl_heap_object_free_storage()
358 spl_ptr_heap_destroy(intern->heap); in spl_heap_object_free_storage()
364 spl_heap_object *intern; in spl_heap_object_new_ex() local
368 intern = ecalloc(1, sizeof(spl_heap_object) + zend_object_properties_size(parent)); in spl_heap_object_new_ex()
370 zend_object_std_init(&intern->std, class_type); in spl_heap_object_new_ex()
371 object_properties_init(&intern->std, class_type); in spl_heap_object_new_ex()
373 intern->flags = 0; in spl_heap_object_new_ex()
374 intern->fptr_cmp = NULL; in spl_heap_object_new_ex()
378 intern->ce_get_iterator = other->ce_get_iterator; in spl_heap_object_new_ex()
381 intern->heap = spl_ptr_heap_clone(other->heap); in spl_heap_object_new_ex()
383 intern->heap = other->heap; in spl_heap_object_new_ex()
386 intern->flags = other->flags; in spl_heap_object_new_ex()
388intern->heap = spl_ptr_heap_init(spl_ptr_heap_zval_max_cmp, spl_ptr_heap_zval_ctor, spl_ptr_heap_z… in spl_heap_object_new_ex()
391 intern->std.handlers = &spl_handler_SplHeap; in spl_heap_object_new_ex()
395 intern->heap->cmp = spl_ptr_pqueue_zval_cmp; in spl_heap_object_new_ex()
396 intern->flags = SPL_PQUEUE_EXTR_DATA; in spl_heap_object_new_ex()
397 intern->std.handlers = &spl_handler_SplPriorityQueue; in spl_heap_object_new_ex()
402 intern->heap->cmp = spl_ptr_heap_zval_min_cmp; in spl_heap_object_new_ex()
407 intern->heap->cmp = spl_ptr_heap_zval_max_cmp; in spl_heap_object_new_ex()
424intern->fptr_cmp = zend_hash_str_find_ptr(&class_type->function_table, "compare", sizeof("compare"… in spl_heap_object_new_ex()
425 if (intern->fptr_cmp->common.scope == parent) { in spl_heap_object_new_ex()
426 intern->fptr_cmp = NULL; in spl_heap_object_new_ex()
428intern->fptr_count = zend_hash_str_find_ptr(&class_type->function_table, "count", sizeof("count") … in spl_heap_object_new_ex()
429 if (intern->fptr_count->common.scope == parent) { in spl_heap_object_new_ex()
430 intern->fptr_count = NULL; in spl_heap_object_new_ex()
434 return &intern->std; in spl_heap_object_new_ex()
460 spl_heap_object *intern = Z_SPLHEAP_P(object); in spl_heap_object_count_elements() local
462 if (intern->fptr_count) { in spl_heap_object_count_elements()
464 zend_call_method_with_0_params(object, intern->std.ce, &intern->fptr_count, "count", &rv); in spl_heap_object_count_elements()
474 *count = spl_ptr_heap_count(intern->heap); in spl_heap_object_count_elements()
481 spl_heap_object *intern = Z_SPLHEAP_P(obj); in spl_heap_object_get_debug_info_helper() local
489 if (!intern->std.properties) { in spl_heap_object_get_debug_info_helper()
490 rebuild_object_properties(&intern->std); in spl_heap_object_get_debug_info_helper()
494 ZEND_INIT_SYMTABLE_EX(debug_info, zend_hash_num_elements(intern->std.properties) + 1, 0); in spl_heap_object_get_debug_info_helper()
495 zend_hash_copy(debug_info, intern->std.properties, (copy_ctor_func_t) zval_add_ref); in spl_heap_object_get_debug_info_helper()
498 ZVAL_LONG(&tmp, intern->flags); in spl_heap_object_get_debug_info_helper()
503 ZVAL_BOOL(&tmp, intern->heap->flags&SPL_HEAP_CORRUPTED); in spl_heap_object_get_debug_info_helper()
509 for (i = 0; i < intern->heap->count; ++i) { in spl_heap_object_get_debug_info_helper()
510 add_index_zval(&heap_array, i, &intern->heap->elements[i]); in spl_heap_object_get_debug_info_helper()
511 if (Z_REFCOUNTED(intern->heap->elements[i])) { in spl_heap_object_get_debug_info_helper()
512 Z_ADDREF(intern->heap->elements[i]); in spl_heap_object_get_debug_info_helper()
526 spl_heap_object *intern = Z_SPLHEAP_P(obj); in spl_heap_object_get_gc() local
527 *gc_data = intern->heap->elements; in spl_heap_object_get_gc()
528 *gc_data_count = intern->heap->count; in spl_heap_object_get_gc()
551 spl_heap_object *intern = Z_SPLHEAP_P(getThis()); in SPL_METHOD() local
557 count = spl_ptr_heap_count(intern->heap); in SPL_METHOD()
566 spl_heap_object *intern = Z_SPLHEAP_P(getThis()); in SPL_METHOD() local
572 RETURN_BOOL(spl_ptr_heap_count(intern->heap) == 0); in SPL_METHOD()
581 spl_heap_object *intern; in SPL_METHOD() local
587 intern = Z_SPLHEAP_P(getThis()); in SPL_METHOD()
589 if (intern->heap->flags & SPL_HEAP_CORRUPTED) { in SPL_METHOD()
595 spl_ptr_heap_insert(intern->heap, value, getThis()); in SPL_METHOD()
605 spl_heap_object *intern; in SPL_METHOD() local
611 intern = Z_SPLHEAP_P(getThis()); in SPL_METHOD()
613 if (intern->heap->flags & SPL_HEAP_CORRUPTED) { in SPL_METHOD()
618 spl_ptr_heap_delete_top(intern->heap, return_value, getThis()); in SPL_METHOD()
632 spl_heap_object *intern; in SPL_METHOD() local
638 intern = Z_SPLHEAP_P(getThis()); in SPL_METHOD()
640 if (intern->heap->flags & SPL_HEAP_CORRUPTED) { in SPL_METHOD()
652 spl_ptr_heap_insert(intern->heap, &elem, getThis()); in SPL_METHOD()
663 spl_heap_object *intern; in SPL_METHOD() local
669 intern = Z_SPLHEAP_P(getThis()); in SPL_METHOD()
671 if (intern->heap->flags & SPL_HEAP_CORRUPTED) { in SPL_METHOD()
676 spl_ptr_heap_delete_top(intern->heap, &value, getThis()); in SPL_METHOD()
683 value_out = spl_pqueue_extract_helper(&value, intern->flags); in SPL_METHOD()
702 spl_heap_object *intern; in SPL_METHOD() local
708 intern = Z_SPLHEAP_P(getThis()); in SPL_METHOD()
710 if (intern->heap->flags & SPL_HEAP_CORRUPTED) { in SPL_METHOD()
715 value = spl_ptr_heap_top(intern->heap); in SPL_METHOD()
722 value_out = spl_pqueue_extract_helper(value, intern->flags); in SPL_METHOD()
740 spl_heap_object *intern; in SPL_METHOD() local
746 intern = Z_SPLHEAP_P(getThis()); in SPL_METHOD()
748 intern->flags = value & SPL_PQUEUE_EXTR_MASK; in SPL_METHOD()
750 RETURN_LONG(intern->flags); in SPL_METHOD()
758 spl_heap_object *intern; in SPL_METHOD() local
764 intern = Z_SPLHEAP_P(getThis()); in SPL_METHOD()
766 RETURN_LONG(intern->flags); in SPL_METHOD()
774 spl_heap_object *intern; in SPL_METHOD() local
780 intern = Z_SPLHEAP_P(getThis()); in SPL_METHOD()
782 intern->heap->flags = intern->heap->flags & ~SPL_HEAP_CORRUPTED; in SPL_METHOD()
792 spl_heap_object *intern; in SPL_METHOD() local
798 intern = Z_SPLHEAP_P(getThis()); in SPL_METHOD()
800 RETURN_BOOL(intern->heap->flags & SPL_HEAP_CORRUPTED); in SPL_METHOD()
823 spl_heap_object *intern; in SPL_METHOD() local
829 intern = Z_SPLHEAP_P(getThis()); in SPL_METHOD()
831 if (intern->heap->flags & SPL_HEAP_CORRUPTED) { in SPL_METHOD()
836 value = spl_ptr_heap_top(intern->heap); in SPL_METHOD()
881 zval_ptr_dtor(&iterator->intern.it.data); in spl_heap_it_dtor()
967 spl_heap_object *intern = Z_SPLHEAP_P(getThis()); in SPL_METHOD() local
973 RETURN_LONG(intern->heap->count - 1); in SPL_METHOD()
981 spl_heap_object *intern = Z_SPLHEAP_P(getThis()); in SPL_METHOD() local
983 spl_ptr_heap_delete_top(intern->heap, &elem, getThis()); in SPL_METHOD()
997 spl_heap_object *intern = Z_SPLHEAP_P(getThis()); in SPL_METHOD() local
1003 RETURN_BOOL(intern->heap->count != 0); in SPL_METHOD()
1022 spl_heap_object *intern = Z_SPLHEAP_P(getThis()); in SPL_METHOD() local
1023 zval *element = &intern->heap->elements[0]; in SPL_METHOD()
1029 if (!intern->heap->count || Z_ISUNDEF_P(element)) { in SPL_METHOD()
1042 spl_heap_object *intern = Z_SPLHEAP_P(getThis()); in SPL_METHOD() local
1043 zval *element = &intern->heap->elements[0]; in SPL_METHOD()
1049 if (!intern->heap->count || Z_ISUNDEF_P(element)) { in SPL_METHOD()
1052 zval *data = spl_pqueue_extract_helper(element, intern->flags); in SPL_METHOD()
1098 zend_iterator_init(&iterator->intern.it); in spl_heap_get_iterator()
1100 ZVAL_COPY(&iterator->intern.it.data, object); in spl_heap_get_iterator()
1101 iterator->intern.it.funcs = &spl_heap_it_funcs; in spl_heap_get_iterator()
1102 iterator->intern.ce = ce; in spl_heap_get_iterator()
1104 ZVAL_UNDEF(&iterator->intern.value); in spl_heap_get_iterator()
1106 return &iterator->intern.it; in spl_heap_get_iterator()
1124 ZVAL_COPY(&iterator->intern.it.data, object); in spl_pqueue_get_iterator()
1125 iterator->intern.it.funcs = &spl_pqueue_it_funcs; in spl_pqueue_get_iterator()
1126 iterator->intern.ce = ce; in spl_pqueue_get_iterator()
1129 ZVAL_UNDEF(&iterator->intern.value); in spl_pqueue_get_iterator()
1131 return &iterator->intern.it; in spl_pqueue_get_iterator()