forked from php/pecl-file_formats-yaml
-
Notifications
You must be signed in to change notification settings - Fork 0
/
zval_refcount.h
58 lines (52 loc) · 2.69 KB
/
zval_refcount.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
/*
+----------------------------------------------------------------------+
| Zend Engine |
+----------------------------------------------------------------------+
| Copyright (c) 1998-2007 Zend Technologies Ltd. (http://www.zend.com) |
+----------------------------------------------------------------------+
| This source file is subject to version 2.00 of the Zend license, |
| that is bundled with this package in the file LICENSE, and is |
| available through the world-wide-web at the following url: |
| http://www.zend.com/license/2_00.txt. |
| If you did not receive a copy of the Zend license and are unable to |
| obtain it through the world-wide-web, please send a note to |
| license@zend.com so we can mail you a copy immediately. |
+----------------------------------------------------------------------+
| Authors: Andi Gutmans <andi@zend.com> |
| Zeev Suraski <zeev@zend.com> |
+----------------------------------------------------------------------+
*/
#ifndef Z_REFCOUNT_P
#define Z_REFCOUNT_PP(ppz) ((*(ppz))->refcount)
#define Z_SET_REFCOUNT_PP(ppz, rc) ((*(ppz))->refcount = rc)
#define Z_ADDREF_PP(ppz) (++(*(ppz))->refcount)
#define Z_DELREF_PP(ppz) (--(*(ppz))->refcount)
#define Z_ISREF_PP(ppz) ((*(ppz))->is_ref)
#define Z_SET_ISREF_PP(ppz) ((*(ppz))->is_ref = 1)
#define Z_UNSET_ISREF_PP(ppz) ((*(ppz))->is_ref = 0)
#define Z_SET_ISREF_TO_PP(ppz, isref) ((*(ppz))->is_ref = isref)
#define Z_REFCOUNT_P(pz) ((pz)->refcount)
#define Z_SET_REFCOUNT_P(z, rc) ((pz)->refcount = rc)
#define Z_ADDREF_P(pz) (++(pz)->refcount)
#define Z_DELREF_P(pz) (--(pz)->refcount)
#define Z_ISREF_P(pz) ((pz)->is_ref)
#define Z_SET_ISREF_P(pz) ((pz)->is_ref = 1)
#define Z_UNSET_ISREF_P(pz) ((pz)->is_ref = 0)
#define Z_SET_ISREF_TO_P(z, isref) ((pz)->is_ref = isref)
#define Z_REFCOUNT(z) ((z).refcount)
#define Z_SET_REFCOUNT(z, rc) ((z).refcount = rc)
#define Z_ADDREF(z) (++(z).refcount)
#define Z_DELREF(z) (--(z).refcount)
#define Z_ISREF(z) ((z).is_ref)
#define Z_SET_ISREF(z) ((z).is_ref = 1)
#define Z_UNSET_ISREF(z) ((z).is_ref = 0)
#define Z_SET_ISREF_TO(z, isref) ((z).is_ref = isref)
#endif /* Z_REFCOUNT_P */
/*
* Local variables:
* tab-width: 4
* c-basic-offset: 4
* End:
* vim600: noet sw=4 ts=4 fdm=marker
* vim<600: noet sw=4 ts=4
*/