Lines Matching refs:func

39 	zend_function  func;  member
50 zend_function *func = EG(current_execute_data)->function_state.function; in ZEND_METHOD() local
74 efree((char*)func->internal_function.function_name); in ZEND_METHOD()
75 efree(func); in ZEND_METHOD()
93 if ((newthis != NULL) && (closure->func.common.fn_flags & ZEND_ACC_STATIC)) { in ZEND_METHOD()
121 ce = closure->func.common.scope; in ZEND_METHOD()
133 ce = closure->func.common.scope; in ZEND_METHOD()
136 zend_create_closure(return_value, &closure->func, ce, newthis TSRMLS_CC); in ZEND_METHOD()
158 invoke->common = closure->func.common; in zend_get_closure_invoke_method()
160 …invoke->internal_function.fn_flags = ZEND_ACC_PUBLIC | ZEND_ACC_CALL_VIA_HANDLER | (closure->func.… in zend_get_closure_invoke_method()
172 return &closure->func; in zend_get_closure_method_def()
243 if (closure->func.type == ZEND_USER_FUNCTION) { in zend_closure_free_storage()
246 if (ex->op_array == &closure->func.op_array) { in zend_closure_free_storage()
251 destroy_op_array(&closure->func.op_array TSRMLS_CC); in zend_closure_free_storage()
289 …zend_create_closure(&result, &closure->func, closure->func.common.scope, closure->this_ptr TSRMLS_… in zend_closure_clone()
303 *fptr_ptr = &closure->func; in zend_closure_get_closure()
314 *ce_ptr = closure->func.common.scope; in zend_closure_get_closure()
324 struct _zend_arg_info *arg_info = closure->func.common.arg_info; in zend_closure_get_debug_info()
333 if (closure->func.type == ZEND_USER_FUNCTION && closure->func.op_array.static_variables) { in zend_closure_get_debug_info()
334 HashTable *static_variables = closure->func.op_array.static_variables; in zend_closure_get_debug_info()
347 zend_uint i, required = closure->func.common.required_num_args; in zend_closure_get_debug_info()
352 for (i = 0; i < closure->func.common.num_args; i++) { in zend_closure_get_debug_info()
384 return (closure->func.type == ZEND_USER_FUNCTION) ? in zend_closure_get_gc()
385 closure->func.op_array.static_variables : NULL; in zend_closure_get_gc()
442 ZEND_API void zend_create_closure(zval *res, zend_function *func, zend_class_entry *scope, zval *th… in zend_create_closure() argument
450 closure->func = *func; in zend_create_closure()
451 closure->func.common.prototype = NULL; in zend_create_closure()
452 closure->func.common.fn_flags |= ZEND_ACC_CLOSURE; in zend_create_closure()
460 if (closure->func.type == ZEND_USER_FUNCTION) { in zend_create_closure()
461 if (closure->func.op_array.static_variables) { in zend_create_closure()
462 HashTable *static_variables = closure->func.op_array.static_variables; in zend_create_closure()
464 ALLOC_HASHTABLE(closure->func.op_array.static_variables); in zend_create_closure()
465 …zend_hash_init(closure->func.op_array.static_variables, zend_hash_num_elements(static_variables), … in zend_create_closure()
466 …variables TSRMLS_CC, (apply_func_args_t)zval_copy_static_var, 1, closure->func.op_array.static_var… in zend_create_closure()
468 closure->func.op_array.run_time_cache = NULL; in zend_create_closure()
469 (*closure->func.op_array.refcount)++; in zend_create_closure()
472 if(func->common.scope != NULL) { in zend_create_closure()
473 if(scope && !instanceof_function(scope, func->common.scope TSRMLS_CC)) { in zend_create_closure()
474 …(E_WARNING, "Cannot bind function %s::%s to scope class %s", func->common.scope->name, func->commo… in zend_create_closure()
477 if(scope && this_ptr && (func->common.fn_flags & ZEND_ACC_STATIC) == 0 && in zend_create_closure()
478 !instanceof_function(Z_OBJCE_P(this_ptr), closure->func.common.scope TSRMLS_CC)) { in zend_create_closure()
479 …ARNING, "Cannot bind function %s::%s to object of class %s", func->common.scope->name, func->commo… in zend_create_closure()
494 closure->func.common.scope = scope; in zend_create_closure()
496 closure->func.common.fn_flags |= ZEND_ACC_PUBLIC; in zend_create_closure()
497 if (this_ptr && (closure->func.common.fn_flags & ZEND_ACC_STATIC) == 0) { in zend_create_closure()
501 closure->func.common.fn_flags |= ZEND_ACC_STATIC; in zend_create_closure()