diff options
| author | Marcus Boerger <helly@php.net> | 2003-08-03 22:03:52 +0000 |
|---|---|---|
| committer | Marcus Boerger <helly@php.net> | 2003-08-03 22:03:52 +0000 |
| commit | 538aad24e3915b6f36dccb640252ea55c7c571d0 (patch) | |
| tree | bf14ba65c58d3c92caedab123af190b267754c61 /Zend | |
| parent | ef5a79bfed814f041fc774491760965fb18c6c0d (diff) | |
| download | php-git-538aad24e3915b6f36dccb640252ea55c7c571d0.tar.gz | |
Fix test and add missing initialization
Diffstat (limited to 'Zend')
| -rw-r--r-- | Zend/zend_compile.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 4ff5de2ef9..1ff9bb1e37 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -932,6 +932,7 @@ void zend_do_begin_function_declaration(znode *function_token, znode *function_n op_array.function_name = name; op_array.return_reference = return_reference; op_array.fn_flags = fn_flags; + op_array.pass_rest_by_reference = 0; op_array.scope = CG(active_class_entry); op_array.prototype = NULL; @@ -1606,7 +1607,15 @@ static zend_bool zend_do_perform_implementation_check(zend_function *fe) } for (i=0; i< fe->common.num_args; i++) { - if (strcmp(fe->common.arg_info[i].class_name, fe->common.prototype->common.arg_info[i].class_name)!=0) { + if (fe->common.arg_info[i].class_name) { + if (fe->common.prototype->common.arg_info[i].class_name) { + if (strcmp(fe->common.arg_info[i].class_name, fe->common.prototype->common.arg_info[i].class_name)!=0) { + return 0; + } + } else { + return 0; + } + } else if (fe->common.prototype->common.arg_info[i].class_name) { return 0; } if (fe->common.arg_info[i].pass_by_reference != fe->common.prototype->common.arg_info[i].pass_by_reference) { |
