zend_op *opline;
lcname = zend_string_tolower(Z_STR_P(name));
-
fbc = zend_hash_find_ptr(CG(function_table), lcname);
+
+ /* Special assert() handling should apply independently of compiler flags. */
+ if (fbc && zend_string_equals_literal(lcname, "assert")) {
+ zend_compile_assert(result, zend_ast_get_list(args_ast), lcname, fbc);
+ zend_string_release(lcname);
+ zval_ptr_dtor(&name_node.u.constant);
+ return;
+ }
+
if (!fbc
+ /* Don't use INIT_FCALL for recursive calls */
+ || (fbc == (zend_function*)CG(active_op_array))
|| (fbc->type == ZEND_INTERNAL_FUNCTION && (CG(compiler_options) & ZEND_COMPILE_IGNORE_INTERNAL_FUNCTIONS))
|| (fbc->type == ZEND_USER_FUNCTION && (CG(compiler_options) & ZEND_COMPILE_IGNORE_USER_FUNCTIONS))
+ || (fbc->type == ZEND_USER_FUNCTION && (CG(compiler_options) & ZEND_COMPILE_IGNORE_OTHER_FILES) && fbc->op_array.filename != CG(active_op_array)->filename)
) {
zend_string_release_ex(lcname, 0);
zend_compile_dynamic_call(result, &name_node, args_ast);