if (ptr->flags) {
if (!(ptr->flags & ZEND_ACC_PPP_MASK)) {
zend_error(error_type, "Invalid access level for %s%s%s() - access must be exactly one of public, protected or private", scope ? scope->name : "", scope ? "::" : "", ptr->fname);
+ internal_function->fn_flags |= ZEND_ACC_PUBLIC;
+ } else {
+ internal_function->fn_flags = ptr->flags;
}
- internal_function->fn_flags = ptr->flags;
} else {
internal_function->fn_flags = ZEND_ACC_PUBLIC;
}