mirror of
https://github.com/php/php-src.git
synced 2024-11-24 02:15:04 +08:00
Intriduced ZEND_ACC_INHERITED class flag.
It's going to be helpful for static optimisations, when "parent" is not known yet.
This commit is contained in:
parent
b281362681
commit
bdc1ba3e3a
@ -5949,6 +5949,7 @@ void zend_compile_class_decl(zend_ast *ast) /* {{{ */
|
||||
}
|
||||
|
||||
zend_compile_class_ref(&extends_node, extends_ast, 0);
|
||||
ce->ce_flags |= ZEND_ACC_INHERITED;
|
||||
}
|
||||
|
||||
opline = get_next_op(CG(active_op_array));
|
||||
|
@ -213,6 +213,7 @@ typedef struct _zend_oparray_context {
|
||||
#define ZEND_ACC_TRAIT 0x80
|
||||
#define ZEND_ACC_ANON_CLASS 0x100
|
||||
#define ZEND_ACC_ANON_BOUND 0x200
|
||||
#define ZEND_ACC_INHERITED 0x400
|
||||
|
||||
/* method flags (visibility) */
|
||||
/* The order of those must be kept - public < protected < private */
|
||||
|
@ -4783,7 +4783,7 @@ ZEND_METHOD(reflection_class, getModifiers)
|
||||
}
|
||||
GET_REFLECTION_OBJECT_PTR(ce);
|
||||
|
||||
RETURN_LONG(ce->ce_flags & ~(ZEND_ACC_CONSTANTS_UPDATED|ZEND_ACC_USE_GUARDS));
|
||||
RETURN_LONG(ce->ce_flags & ~(ZEND_ACC_CONSTANTS_UPDATED|ZEND_ACC_USE_GUARDS|ZEND_ACC_INHERITED));
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user