summaryrefslogtreecommitdiff
path: root/Zend/zend_compile.c
diff options
context:
space:
mode:
Diffstat (limited to 'Zend/zend_compile.c')
-rw-r--r--Zend/zend_compile.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c
index 1323dbc778..2e98f10c6a 100644
--- a/Zend/zend_compile.c
+++ b/Zend/zend_compile.c
@@ -1608,6 +1608,10 @@ ZEND_API void zend_initialize_class_data(zend_class_entry *ce, zend_bool nullify
ce->refcount = 1;
ce->ce_flags = ZEND_ACC_CONSTANTS_UPDATED;
+ if (CG(compiler_options) & ZEND_COMPILE_GUARDS) {
+ ce->ce_flags |= ZEND_ACC_USE_GUARDS;
+ }
+
ce->default_properties_table = NULL;
ce->default_static_members_table = NULL;
zend_hash_init_ex(&ce->properties_info, 8, NULL, (persistent_hashes ? zend_destroy_property_info_internal : NULL), persistent_hashes, 0);