ZSTR_VAL(fbc->common.scope->name), ZSTR_VAL(fbc->common.function_name));
}
-static zend_never_inline ZEND_COLD void ZEND_FASTCALL zend_param_must_be_ref(const zend_function *func, uint32_t arg_num)
+ZEND_COLD void ZEND_FASTCALL zend_param_must_be_ref(const zend_function *func, uint32_t arg_num)
{
const char *arg_name = get_function_arg_name(func, arg_num);
ZEND_API ZEND_COLD void ZEND_FASTCALL zend_missing_arg_error(zend_execute_data *execute_data);
ZEND_API ZEND_COLD void ZEND_FASTCALL zend_deprecated_function(const zend_function *fbc);
+ZEND_COLD void ZEND_FASTCALL zend_param_must_be_ref(const zend_function *func, uint32_t arg_num);
ZEND_API zend_bool ZEND_FASTCALL zend_verify_ref_assignable_zval(zend_reference *ref, zval *zv, zend_bool strict);
ZEND_API zend_bool ZEND_FASTCALL zend_verify_prop_assignable_by_ref(zend_property_info *prop_info, zval *orig_val, zend_bool strict);
} else if (!ARG_MAY_BE_SENT_BY_REF(func, i + 1)) {
/* By-value send is not allowed -- emit a warning,
* but still perform the call with a by-value send. */
- const char *arg_name = get_function_arg_name(func, i + 1);
-
- zend_error(E_WARNING,
- "%s%s%s(): Argument #%d%s%s%s must be passed by reference, value given",
- func->common.scope ? ZSTR_VAL(func->common.scope->name) : "",
- func->common.scope ? "::" : "",
- ZSTR_VAL(func->common.function_name),
- i+1,
- arg_name ? " ($" : "",
- arg_name ? arg_name : "",
- arg_name ? ")" : ""
- );
+ zend_param_must_be_ref(func, i + 1);
if (UNEXPECTED(EG(exception))) {
ZEND_CALL_NUM_ARGS(call) = i;
zend_vm_stack_free_args(call);