summaryrefslogtreecommitdiff
path: root/ext/dom/php_dom.h
diff options
context:
space:
mode:
authorXinchen Hui <laruence@gmail.com>2014-04-21 14:14:00 +0800
committerXinchen Hui <laruence@gmail.com>2014-04-21 14:14:00 +0800
commite48b9ad197b4ec6ac72e75538453cc350d0a41f4 (patch)
treef5ded37abc65e64e270b6f1ac264db9bc603f949 /ext/dom/php_dom.h
parentcf7e703813e065fec7a8a5caa7aff4b70d3455b8 (diff)
parent54d9ad53f4797733b41bf2c65bd2c2cb5a1938b6 (diff)
downloadphp-git-e48b9ad197b4ec6ac72e75538453cc350d0a41f4.tar.gz
Merge branch 'refactoring2' of github.com:zendtech/php into refactoring2
Diffstat (limited to 'ext/dom/php_dom.h')
-rw-r--r--ext/dom/php_dom.h14
1 files changed, 9 insertions, 5 deletions
diff --git a/ext/dom/php_dom.h b/ext/dom/php_dom.h
index 8f6eba12c0..628a19e978 100644
--- a/ext/dom/php_dom.h
+++ b/ext/dom/php_dom.h
@@ -68,18 +68,22 @@ extern zend_module_entry dom_module_entry;
#define DOM_NODESET XML_XINCLUDE_START
typedef struct _dom_xpath_object {
- zend_object std;
- void *ptr;
- php_libxml_ref_obj *document;
- HashTable *prop_handler;
- //??? zend_object_handle handle;
int registerPhpFunctions;
HashTable *registered_phpfunctions;
HashTable *node_list;
+ dom_object dom;
} dom_xpath_object;
+static inline dom_xpath_object *php_xpath_obj_from_obj(zend_object *obj) {
+ return (dom_xpath_object*)((char*)(obj)
+ - XtOffsetOf(dom_xpath_object, dom) - XtOffsetOf(dom_object, std));
+}
+
+#define Z_XPATHOBJ_P(zv) php_xpath_obj_from_obj(Z_OBJ_P((zv)))
+
typedef struct _dom_nnodemap_object {
dom_object *baseobj;
+ zval baseobj_zv;
int nodetype;
xmlHashTable *ht;
xmlChar *local;