mirror of
https://github.com/php/php-src.git
synced 2026-04-10 09:33:06 +02:00
Draft 3 of IEEE 1003.1 200x, "2.2 The Compilation Environment"
All identifiers that begin with an underscore and either an uppercase
letter or another underscore are always reserved for any use by the
implementation.
23 lines
758 B
C
23 lines
758 B
C
#ifndef ZEND_EXECUTE_LOCKS_H
|
|
#define ZEND_EXECUTE_LOCKS_H
|
|
|
|
#define PZVAL_LOCK(z) ((z)->refcount++)
|
|
#define PZVAL_UNLOCK(z) { ((z)->refcount--); \
|
|
if (!(z)->refcount) { \
|
|
(z)->refcount = 1; \
|
|
(z)->is_ref = 0; \
|
|
EG(garbage)[EG(garbage_ptr)++] = (z); \
|
|
if (EG(garbage_ptr) == 4) { \
|
|
zval_ptr_dtor(&EG(garbage)[0]); \
|
|
zval_ptr_dtor(&EG(garbage)[1]); \
|
|
EG(garbage)[0] = EG(garbage)[2]; \
|
|
EG(garbage)[1] = EG(garbage)[3]; \
|
|
EG(garbage_ptr) -= 2; \
|
|
} \
|
|
} \
|
|
}
|
|
|
|
#define SELECTIVE_PZVAL_LOCK(pzv, pzn) if (!((pzn)->u.EA.type & EXT_TYPE_UNUSED)) { PZVAL_LOCK(pzv); }
|
|
|
|
#endif /* ZEND_EXECUTE_LOCKS_H */
|