summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Silverstone <dsilvers@netsurf-browser.org>2012-03-28 20:41:01 +0000
committerDaniel Silverstone <dsilvers@netsurf-browser.org>2012-03-28 20:41:01 +0000
commitf57213206237c62ced97638a665f10c986c64137 (patch)
tree7dc3d87784439db9ada9ea0f6b04210be26f9825
parent896be5bbd25299833957e51473656ffcf7b61318 (diff)
downloadlibdom-f57213206237c62ced97638a665f10c986c64137.tar.gz
libdom-f57213206237c62ced97638a665f10c986c64137.tar.bz2
Remove casts related to dom_string in API macros because they were hiding errors such as the one fixed in r13764
svn path=/trunk/libdom/; revision=13765
-rw-r--r--include/dom/core/attr.h9
-rw-r--r--include/dom/core/characterdata.h13
-rw-r--r--include/dom/core/document.h44
-rw-r--r--include/dom/core/document_type.h8
-rw-r--r--include/dom/core/element.h38
-rw-r--r--include/dom/core/namednodemap.h9
-rw-r--r--include/dom/core/node.h44
-rw-r--r--include/dom/core/text.h5
-rw-r--r--include/dom/core/typeinfo.h8
9 files changed, 74 insertions, 104 deletions
diff --git a/include/dom/core/attr.h b/include/dom/core/attr.h
index 10d4a79..69612f7 100644
--- a/include/dom/core/attr.h
+++ b/include/dom/core/attr.h
@@ -56,8 +56,7 @@ static inline dom_exception dom_attr_get_name(struct dom_attr *attr,
return ((dom_attr_vtable *) ((dom_node *) attr)->vtable)->
dom_attr_get_name(attr, result);
}
-#define dom_attr_get_name(a, r) dom_attr_get_name((struct dom_attr *) (a), \
- (dom_string **) (r))
+#define dom_attr_get_name(a, r) dom_attr_get_name((struct dom_attr *) (a), (r))
static inline dom_exception dom_attr_get_specified(struct dom_attr *attr,
bool *result)
@@ -74,8 +73,7 @@ static inline dom_exception dom_attr_get_value(struct dom_attr *attr,
return ((dom_attr_vtable *) ((dom_node *) attr)->vtable)->
dom_attr_get_value(attr, result);
}
-#define dom_attr_get_value(a, r) dom_attr_get_value((struct dom_attr *) (a), \
- (dom_string **) (r))
+#define dom_attr_get_value(a, r) dom_attr_get_value((struct dom_attr *) (a), (r))
static inline dom_exception dom_attr_set_value(struct dom_attr *attr,
dom_string *value)
@@ -83,8 +81,7 @@ static inline dom_exception dom_attr_set_value(struct dom_attr *attr,
return ((dom_attr_vtable *) ((dom_node *) attr)->vtable)->
dom_attr_set_value(attr, value);
}
-#define dom_attr_set_value(a, v) dom_attr_set_value((struct dom_attr *) (a), \
- (dom_string *) (v))
+#define dom_attr_set_value(a, v) dom_attr_set_value((struct dom_attr *) (a), (v))
static inline dom_exception dom_attr_get_owner_element(struct dom_attr *attr,
struct dom_element **result)
diff --git a/include/dom/core/characterdata.h b/include/dom/core/characterdata.h
index 322fb03..174be89 100644
--- a/include/dom/core/characterdata.h
+++ b/include/dom/core/characterdata.h
@@ -51,7 +51,7 @@ static inline dom_exception dom_characterdata_get_data(
dom_characterdata_get_data(cdata, data);
}
#define dom_characterdata_get_data(c, d) dom_characterdata_get_data( \
- (struct dom_characterdata *) (c), (dom_string **) (d))
+ (struct dom_characterdata *) (c), (d))
static inline dom_exception dom_characterdata_set_data(
struct dom_characterdata *cdata, dom_string *data)
@@ -60,7 +60,7 @@ static inline dom_exception dom_characterdata_set_data(
dom_characterdata_set_data(cdata, data);
}
#define dom_characterdata_set_data(c, d) dom_characterdata_set_data( \
- (struct dom_characterdata *) (c), (dom_string *) (d))
+ (struct dom_characterdata *) (c), (d))
static inline dom_exception dom_characterdata_get_length(
struct dom_characterdata *cdata, unsigned long *length)
@@ -82,7 +82,7 @@ static inline dom_exception dom_characterdata_substring_data(
#define dom_characterdata_substring_data(c, o, ct, d) \
dom_characterdata_substring_data( \
(struct dom_characterdata *) (c), (unsigned long) (o), \
- (unsigned long) (ct), (dom_string **) (d))
+ (unsigned long) (ct), (d))
static inline dom_exception dom_characterdata_append_data(
struct dom_characterdata *cdata, dom_string *data)
@@ -91,7 +91,7 @@ static inline dom_exception dom_characterdata_append_data(
dom_characterdata_append_data(cdata, data);
}
#define dom_characterdata_append_data(c, d) dom_characterdata_append_data( \
- (struct dom_characterdata *) (c), (dom_string *) (d))
+ (struct dom_characterdata *) (c), (d))
static inline dom_exception dom_characterdata_insert_data(
struct dom_characterdata *cdata, unsigned long offset,
@@ -101,8 +101,7 @@ static inline dom_exception dom_characterdata_insert_data(
dom_characterdata_insert_data(cdata, offset, data);
}
#define dom_characterdata_insert_data(c, o, d) dom_characterdata_insert_data( \
- (struct dom_characterdata *) (c), (unsigned long) (o), \
- (dom_string *) (d))
+ (struct dom_characterdata *) (c), (unsigned long) (o), (d))
static inline dom_exception dom_characterdata_delete_data(
struct dom_characterdata *cdata, unsigned long offset,
@@ -126,6 +125,6 @@ static inline dom_exception dom_characterdata_replace_data(
#define dom_characterdata_replace_data(c, o, ct, d) \
dom_characterdata_replace_data(\
(struct dom_characterdata *) (c), (unsigned long) (o),\
- (unsigned long) (ct), (dom_string *) (d))
+ (unsigned long) (ct), (d))
#endif
diff --git a/include/dom/core/document.h b/include/dom/core/document.h
index 31a46b3..de3e07a 100644
--- a/include/dom/core/document.h
+++ b/include/dom/core/document.h
@@ -166,7 +166,7 @@ static inline dom_exception dom_document_create_element(
dom_document_create_element(doc, tag_name, result);
}
#define dom_document_create_element(d, t, r) dom_document_create_element( \
- (dom_document *) (d), (dom_string *) (t), \
+ (dom_document *) (d), (t), \
(struct dom_element **) (r))
static inline dom_exception dom_document_create_document_fragment(
@@ -189,7 +189,7 @@ static inline dom_exception dom_document_create_text_node(
}
#define dom_document_create_text_node(d, data, r) \
dom_document_create_text_node((dom_document *) (d), \
- (dom_string *) (data), (struct dom_text **) (r))
+ (data), (struct dom_text **) (r))
static inline dom_exception dom_document_create_comment(
struct dom_document *doc, dom_string *data,
@@ -199,7 +199,7 @@ static inline dom_exception dom_document_create_comment(
dom_document_create_comment(doc, data, result);
}
#define dom_document_create_comment(d, data, r) dom_document_create_comment( \
- (dom_document *) (d), (dom_string *) (data), \
+ (dom_document *) (d), (data), \
(struct dom_comment **) (r))
static inline dom_exception dom_document_create_cdata_section(
@@ -211,8 +211,7 @@ static inline dom_exception dom_document_create_cdata_section(
}
#define dom_document_create_cdata_section(d, data, r) \
dom_document_create_cdata_section((dom_document *) (d), \
- (dom_string *) (data), \
- (struct dom_cdata_section **) (r))
+ (data), (struct dom_cdata_section **) (r))
static inline dom_exception dom_document_create_processing_instruction(
struct dom_document *doc, dom_string *target,
@@ -225,8 +224,7 @@ static inline dom_exception dom_document_create_processing_instruction(
}
#define dom_document_create_processing_instruction(d, t, data, r) \
dom_document_create_processing_instruction( \
- (dom_document *) (d), (dom_string *) (t), \
- (dom_string *) (data), \
+ (dom_document *) (d), (t), (data), \
(struct dom_processing_instruction **) (r))
static inline dom_exception dom_document_create_attribute(
@@ -237,7 +235,7 @@ static inline dom_exception dom_document_create_attribute(
dom_document_create_attribute(doc, name, result);
}
#define dom_document_create_attribute(d, n, r) dom_document_create_attribute( \
- (dom_document *) (d), (dom_string *) (n), \
+ (dom_document *) (d), (n), \
(struct dom_attr **) (r))
static inline dom_exception dom_document_create_entity_reference(
@@ -250,7 +248,7 @@ static inline dom_exception dom_document_create_entity_reference(
}
#define dom_document_create_entity_reference(d, n, r) \
dom_document_create_entity_reference((dom_document *) (d), \
- (dom_string *) (n), (struct dom_entity_reference **) (r))
+ (n), (struct dom_entity_reference **) (r))
static inline dom_exception dom_document_get_elements_by_tag_name(
struct dom_document *doc, dom_string *tagname,
@@ -262,7 +260,7 @@ static inline dom_exception dom_document_get_elements_by_tag_name(
}
#define dom_document_get_elements_by_tag_name(d, t, r) \
dom_document_get_elements_by_tag_name((dom_document *) (d), \
- (dom_string *) (t), (struct dom_nodelist **) (r))
+ (t), (struct dom_nodelist **) (r))
static inline dom_exception dom_document_import_node(struct dom_document *doc,
struct dom_node *node, bool deep, struct dom_node **result)
@@ -284,7 +282,7 @@ static inline dom_exception dom_document_create_element_ns(
}
#define dom_document_create_element_ns(d, n, q, r) \
dom_document_create_element_ns((dom_document *) (d), \
- (dom_string *) (n), (dom_string *) (q), \
+ (n), (q), \
(struct dom_element **) (r))
static inline dom_exception dom_document_create_attribute_ns
@@ -297,8 +295,7 @@ static inline dom_exception dom_document_create_attribute_ns
}
#define dom_document_create_attribute_ns(d, n, q, r) \
dom_document_create_attribute_ns((dom_document *) (d), \
- (dom_string *) (n), (dom_string *) (q), \
- (struct dom_attr **) (r))
+ (n), (q), (struct dom_attr **) (r))
static inline dom_exception dom_document_get_elements_by_tag_name_ns(
struct dom_document *doc, dom_string *namespace,
@@ -310,8 +307,7 @@ static inline dom_exception dom_document_get_elements_by_tag_name_ns(
}
#define dom_document_get_elements_by_tag_name_ns(d, n, l, r) \
dom_document_get_elements_by_tag_name_ns((dom_document *) (d),\
- (dom_string *) (n), (dom_string *) (l), \
- (struct dom_nodelist **) (r))
+ (n), (l), (struct dom_nodelist **) (r))
static inline dom_exception dom_document_get_element_by_id(
struct dom_document *doc, dom_string *id,
@@ -322,7 +318,7 @@ static inline dom_exception dom_document_get_element_by_id(
}
#define dom_document_get_element_by_id(d, i, r) \
dom_document_get_element_by_id((dom_document *) (d), \
- (dom_string *) (i), (struct dom_element **) (r))
+ (i), (struct dom_element **) (r))
static inline dom_exception dom_document_get_input_encoding(
struct dom_document *doc, dom_string **result)
@@ -331,7 +327,7 @@ static inline dom_exception dom_document_get_input_encoding(
dom_document_get_input_encoding(doc, result);
}
#define dom_document_get_input_encoding(d, r) dom_document_get_input_encoding(\
- (dom_document *) (d), (dom_string **) (r))
+ (dom_document *) (d), (r))
static inline dom_exception dom_document_get_xml_encoding(
struct dom_document *doc, dom_string **result)
@@ -340,7 +336,7 @@ static inline dom_exception dom_document_get_xml_encoding(
dom_document_get_xml_encoding(doc, result);
}
#define dom_document_get_xml_encoding(d, r) dom_document_get_xml_encoding( \
- (dom_document *) (d), (dom_string **) (r))
+ (dom_document *) (d), (r))
static inline dom_exception dom_document_get_xml_standalone(
struct dom_document *doc, bool *result)
@@ -367,7 +363,7 @@ static inline dom_exception dom_document_get_xml_version(
dom_document_get_xml_version(doc, result);
}
#define dom_document_get_xml_version(d, r) dom_document_get_xml_version( \
- (dom_document *) (d), (dom_string **) (r))
+ (dom_document *) (d), (r))
static inline dom_exception dom_document_set_xml_version(
struct dom_document *doc, dom_string *version)
@@ -376,7 +372,7 @@ static inline dom_exception dom_document_set_xml_version(
dom_document_set_xml_version(doc, version);
}
#define dom_document_set_xml_version(d, v) dom_document_set_xml_version( \
- (dom_document *) (d), (dom_string *) (v))
+ (dom_document *) (d), (v))
static inline dom_exception dom_document_get_strict_error_checking(
struct dom_document *doc, bool *result)
@@ -405,7 +401,7 @@ static inline dom_exception dom_document_get_uri(struct dom_document *doc,
dom_document_get_uri(doc, result);
}
#define dom_document_get_uri(d, r) dom_document_get_uri((dom_document *) (d), \
- (dom_string **) (r))
+ (r))
static inline dom_exception dom_document_set_uri(struct dom_document *doc,
dom_string *uri)
@@ -414,7 +410,7 @@ static inline dom_exception dom_document_set_uri(struct dom_document *doc,
dom_document_set_uri(doc, uri);
}
#define dom_document_set_uri(d, u) dom_document_set_uri((dom_document *) (d), \
- (dom_string *) (u))
+ (u))
static inline dom_exception dom_document_adopt_node(struct dom_document *doc,
struct dom_node *node, struct dom_node **result)
@@ -451,8 +447,8 @@ static inline dom_exception dom_document_rename_node(struct dom_document *doc,
result);
}
#define dom_document_rename_node(d, n, ns, q, r) dom_document_rename_node( \
- (dom_document *) (d), (dom_string *) (ns), \
- (dom_string *) (q), (dom_node **) (r))
+ (dom_document *) (d), (ns), \
+ (q), (dom_node **) (r))
static inline dom_exception dom_document_get_quirks_mode(
dom_document *doc, dom_document_quirks_mode *result)
diff --git a/include/dom/core/document_type.h b/include/dom/core/document_type.h
index 989ff69..4f4841a 100644
--- a/include/dom/core/document_type.h
+++ b/include/dom/core/document_type.h
@@ -46,7 +46,7 @@ static inline dom_exception dom_document_type_get_name(
->dom_document_type_get_name(doc_type, result);
}
#define dom_document_type_get_name(dt, r) dom_document_type_get_name( \
- (dom_document_type *) (dt), (dom_string **) (r))
+ (dom_document_type *) (dt), (r))
static inline dom_exception dom_document_type_get_entities(
struct dom_document_type *doc_type,
@@ -77,7 +77,7 @@ static inline dom_exception dom_document_type_get_public_id(
}
#define dom_document_type_get_public_id(dt, r) \
dom_document_type_get_public_id((dom_document_type *) (dt), \
- (dom_string **) (r))
+ (r))
static inline dom_exception dom_document_type_get_system_id(
struct dom_document_type *doc_type,
@@ -88,7 +88,7 @@ static inline dom_exception dom_document_type_get_system_id(
}
#define dom_document_type_get_system_id(dt, r) \
dom_document_type_get_system_id((dom_document_type *) (dt), \
- (dom_string **) (r))
+ (r))
static inline dom_exception dom_document_type_get_internal_subset(
struct dom_document_type *doc_type,
@@ -100,7 +100,7 @@ static inline dom_exception dom_document_type_get_internal_subset(
}
#define dom_document_type_get_internal_subset(dt, r) \
dom_document_type_get_internal_subset( \
- (dom_document_type *) (dt), (dom_string **) (r))
+ (dom_document_type *) (dt), (r))
#endif
diff --git a/include/dom/core/element.h b/include/dom/core/element.h
index 91b763f..3e0fcb3 100644
--- a/include/dom/core/element.h
+++ b/include/dom/core/element.h
@@ -104,7 +104,7 @@ static inline dom_exception dom_element_get_tag_name(
dom_element_get_tag_name(element, name);
}
#define dom_element_get_tag_name(e, n) dom_element_get_tag_name( \
- (dom_element *) (e), (dom_string **) (n))
+ (dom_element *) (e), (n))
static inline dom_exception dom_element_get_attribute(
struct dom_element *element, dom_string *name,
@@ -114,8 +114,7 @@ static inline dom_exception dom_element_get_attribute(
dom_element_get_attribute(element, name, value);
}
#define dom_element_get_attribute(e, n, v) dom_element_get_attribute( \
- (dom_element *) (e), (dom_string *) (n), \
- (dom_string **) (v))
+ (dom_element *) (e), (n), (v))
static inline dom_exception dom_element_set_attribute(
struct dom_element *element, dom_string *name,
@@ -125,8 +124,7 @@ static inline dom_exception dom_element_set_attribute(
dom_element_set_attribute(element, name, value);
}
#define dom_element_set_attribute(e, n, v) dom_element_set_attribute( \
- (dom_element *) (e), (dom_string *) (n), \
- (dom_string *) (v))
+ (dom_element *) (e), (n), (v))
static inline dom_exception dom_element_remove_attribute(
struct dom_element *element, dom_string *name)
@@ -135,7 +133,7 @@ static inline dom_exception dom_element_remove_attribute(
dom_element_remove_attribute(element, name);
}
#define dom_element_remove_attribute(e, n) dom_element_remove_attribute( \
- (dom_element *) (e), (dom_string *) (n))
+ (dom_element *) (e), (n))
static inline dom_exception dom_element_get_attribute_node(
struct dom_element *element, dom_string *name,
@@ -146,7 +144,7 @@ static inline dom_exception dom_element_get_attribute_node(
}
#define dom_element_get_attribute_node(e, n, r) \
dom_element_get_attribute_node((dom_element *) (e), \
- (dom_string *) (n), (struct dom_attr **) (r))
+ (n), (struct dom_attr **) (r))
static inline dom_exception dom_element_set_attribute_node(
struct dom_element *element, struct dom_attr *attr,
@@ -182,7 +180,7 @@ static inline dom_exception dom_element_get_elements_by_tag_name(
}
#define dom_element_get_elements_by_tag_name(e, n, r) \
dom_element_get_elements_by_tag_name((dom_element *) (e), \
- (dom_string *) (n), (struct dom_nodelist **) (r))
+ (n), (struct dom_nodelist **) (r))
static inline dom_exception dom_element_get_attribute_ns(
struct dom_element *element, dom_string *namespace,
@@ -194,8 +192,7 @@ static inline dom_exception dom_element_get_attribute_ns(
}
#define dom_element_get_attribute_ns(e, n, l, v) \
dom_element_get_attribute_ns((dom_element *) (e), \
- (dom_string *) (n), (dom_string *) (l), \
- (dom_string **) (v))
+ (n), (l), (v))
static inline dom_exception dom_element_set_attribute_ns(
struct dom_element *element, dom_string *namespace,
@@ -207,8 +204,7 @@ static inline dom_exception dom_element_set_attribute_ns(
}
#define dom_element_set_attribute_ns(e, n, l, v) \
dom_element_set_attribute_ns((dom_element *) (e), \
- (dom_string *) (n), (dom_string *) (l), \
- (dom_string *) (v))
+ (n), (l), (v))
static inline dom_exception dom_element_remove_attribute_ns(
@@ -221,7 +217,7 @@ static inline dom_exception dom_element_remove_attribute_ns(
}
#define dom_element_remove_attribute_ns(e, n, l) \
dom_element_remove_attribute_ns((dom_element *) (e), \
- (dom_string *) (n), (dom_string *) (l))
+ (n), (l))
static inline dom_exception dom_element_get_attribute_node_ns(
@@ -234,7 +230,7 @@ static inline dom_exception dom_element_get_attribute_node_ns(
}
#define dom_element_get_attribute_node_ns(e, n, l, r) \
dom_element_get_attribute_node_ns((dom_element *) (e), \
- (dom_string *) (n), (dom_string *) (l), \
+ (n), (l), \
(struct dom_attr **) (r))
static inline dom_exception dom_element_set_attribute_node_ns(
@@ -259,8 +255,7 @@ static inline dom_exception dom_element_get_elements_by_tag_name_ns(
}
#define dom_element_get_elements_by_tag_name_ns(e, n, l, r) \
dom_element_get_elements_by_tag_name_ns((dom_element *) (e), \
- (dom_string *) (n), (dom_string *) (l), \
- (struct dom_nodelist **) (r))
+ (n), (l), (struct dom_nodelist **) (r))
static inline dom_exception dom_element_has_attribute(
struct dom_element *element, dom_string *name,
@@ -270,8 +265,7 @@ static inline dom_exception dom_element_has_attribute(
dom_element_has_attribute(element, name, result);
}
#define dom_element_has_attribute(e, n, r) dom_element_has_attribute( \
- (dom_element *) (e), (dom_string *) (n), \
- (bool *) (r))
+ (dom_element *) (e), (n), (bool *) (r))
static inline dom_exception dom_element_has_attribute_ns(
struct dom_element *element, dom_string *namespace,
@@ -282,8 +276,7 @@ static inline dom_exception dom_element_has_attribute_ns(
localname, result);
}
#define dom_element_has_attribute_ns(e, n, l, r) dom_element_has_attribute_ns(\
- (dom_element *) (e), (dom_string *) (n), \
- (dom_string *) (l), (bool *) (r))
+ (dom_element *) (e), (n), (l), (bool *) (r))
static inline dom_exception dom_element_get_schema_type_info(
struct dom_element *element, struct dom_type_info **result)
@@ -304,7 +297,7 @@ static inline dom_exception dom_element_set_id_attribute(
}
#define dom_element_set_id_attribute(e, n, i) \
dom_element_set_id_attribute((dom_element *) (e), \
- (dom_string *) (n), (bool) (i))
+ (n), (bool) (i))
static inline dom_exception dom_element_set_id_attribute_ns(
struct dom_element *element, dom_string *namespace,
@@ -316,8 +309,7 @@ static inline dom_exception dom_element_set_id_attribute_ns(
}
#define dom_element_set_id_attribute_ns(e, n, l, i) \
dom_element_set_id_attribute_ns((dom_element *) (e), \
- (dom_string *) (n), (dom_string *) (l), \
- (bool) (i))
+ (n), (l), (bool) (i))
static inline dom_exception dom_element_set_id_attribute_node(
struct dom_element *element, struct dom_attr *id_attr,
diff --git a/include/dom/core/namednodemap.h b/include/dom/core/namednodemap.h
index ad2494b..fc5e886 100644
--- a/include/dom/core/namednodemap.h
+++ b/include/dom/core/namednodemap.h
@@ -26,7 +26,7 @@ dom_exception _dom_namednodemap_get_named_item(struct dom_namednodemap *map,
#define dom_namednodemap_get_named_item(m, n, r) \
_dom_namednodemap_get_named_item((dom_namednodemap *) (m), \
- (dom_string *) (n), (dom_node **) (r))
+ (n), (dom_node **) (r))
dom_exception _dom_namednodemap_set_named_item(struct dom_namednodemap *map,
@@ -43,7 +43,7 @@ dom_exception _dom_namednodemap_remove_named_item(
#define dom_namednodemap_remove_named_item(m, n, r) \
_dom_namednodemap_remove_named_item((dom_namednodemap *) (m), \
- (dom_string *) (n), (dom_node **) (r))
+ (n), (dom_node **) (r))
dom_exception _dom_namednodemap_item(struct dom_namednodemap *map,
@@ -60,7 +60,7 @@ dom_exception _dom_namednodemap_get_named_item_ns(
#define dom_namednodemap_get_named_item_ns(m, n, l, r) \
_dom_namednodemap_get_named_item_ns((dom_namednodemap *) (m), \
- (dom_string *) (n), (dom_string *) (l), (dom_node **) (r))
+ (n), (l), (dom_node **) (r))
dom_exception _dom_namednodemap_set_named_item_ns(
@@ -78,7 +78,6 @@ dom_exception _dom_namednodemap_remove_named_item_ns(
#define dom_namednodemap_remove_named_item_ns(m, n, l, r) \
_dom_namednodemap_remove_named_item_ns(\
- (dom_namednodemap *) (m), (dom_string *) (n),\
- (dom_string *) (l), (dom_node **) (r))
+ (dom_namednodemap *) (m), (n),(l), (dom_node **) (r))
#endif
diff --git a/include/dom/core/node.h b/include/dom/core/node.h
index 87f1af0..668206f 100644
--- a/include/dom/core/node.h
+++ b/include/dom/core/node.h
@@ -208,8 +208,7 @@ static inline dom_exception dom_node_get_node_name(struct dom_node *node,
return ((dom_node_vtable *) node->vtable)->dom_node_get_node_name(
(dom_node_internal *) node, result);
}
-#define dom_node_get_node_name(n, r) dom_node_get_node_name((dom_node *) (n), \
- (dom_string **) (r))
+#define dom_node_get_node_name(n, r) dom_node_get_node_name((dom_node *) (n), (r))
static inline dom_exception dom_node_get_node_value(struct dom_node *node,
dom_string **result)
@@ -218,7 +217,7 @@ static inline dom_exception dom_node_get_node_value(struct dom_node *node,
(dom_node_internal *) node, result);
}
#define dom_node_get_node_value(n, r) dom_node_get_node_value( \
- (dom_node *) (n), (dom_string **) (r))
+ (dom_node *) (n), (r))
static inline dom_exception dom_node_set_node_value(struct dom_node *node,
dom_string *value)
@@ -227,7 +226,7 @@ static inline dom_exception dom_node_set_node_value(struct dom_node *node,
(dom_node_internal *) node, value);
}
#define dom_node_set_node_value(n, v) dom_node_set_node_value( \
- (dom_node *) (n), (dom_string *) (v))
+ (dom_node *) (n), (v))
static inline dom_exception dom_node_get_node_type(struct dom_node *node,
dom_node_type *result)
@@ -403,8 +402,7 @@ static inline dom_exception dom_node_is_supported(struct dom_node *node,
version, result);
}
#define dom_node_is_supported(n, f, v, r) dom_node_is_supported( \
- (dom_node *) (n), (dom_string *) (f), \
- (dom_string *) (v), (bool *) (r))
+ (dom_node *) (n), (f), (v), (bool *) (r))
static inline dom_exception dom_node_get_namespace(struct dom_node *node,
dom_string **result)
@@ -412,8 +410,7 @@ static inline dom_exception dom_node_get_namespace(struct dom_node *node,
return ((dom_node_vtable *) node->vtable)->dom_node_get_namespace(
(dom_node_internal *) node, result);
}
-#define dom_node_get_namespace(n, r) dom_node_get_namespace((dom_node *) (n), \
- (dom_string **) (r))
+#define dom_node_get_namespace(n, r) dom_node_get_namespace((dom_node *) (n), (r))
static inline dom_exception dom_node_get_prefix(struct dom_node *node,
dom_string **result)
@@ -421,8 +418,7 @@ static inline dom_exception dom_node_get_prefix(struct dom_node *node,
return ((dom_node_vtable *) node->vtable)->dom_node_get_prefix(
(dom_node_internal *) node, result);
}
-#define dom_node_get_prefix(n, r) dom_node_get_prefix((dom_node *) (n), \
- (dom_string **) (r))
+#define dom_node_get_prefix(n, r) dom_node_get_prefix((dom_node *) (n), (r))
static inline dom_exception dom_node_set_prefix(struct dom_node *node,
dom_string *prefix)
@@ -430,8 +426,7 @@ static inline dom_exception dom_node_set_prefix(struct dom_node *node,
return ((dom_node_vtable *) node->vtable)->dom_node_set_prefix(
(dom_node_internal *) node, prefix);
}
-#define dom_node_set_prefix(n, p) dom_node_set_prefix((dom_node *) (n), \
- (dom_string *) (p))
+#define dom_node_set_prefix(n, p) dom_node_set_prefix((dom_node *) (n), (p))
static inline dom_exception dom_node_get_local_name(struct dom_node *node,
dom_string **result)
@@ -439,8 +434,7 @@ static inline dom_exception dom_node_get_local_name(struct dom_node *node,
return ((dom_node_vtable *) node->vtable)->dom_node_get_local_name(
(dom_node_internal *) node, result);
}
-#define dom_node_get_local_name(n, r) dom_node_get_local_name((dom_node *) (n),\
- (dom_string **) (r))
+#define dom_node_get_local_name(n, r) dom_node_get_local_name((dom_node *) (n), (r))
static inline dom_exception dom_node_has_attributes(struct dom_node *node,
bool *result)
@@ -457,8 +451,7 @@ static inline dom_exception dom_node_get_base(struct dom_node *node,
return ((dom_node_vtable *) node->vtable)->dom_node_get_base(
(dom_node_internal *) node, result);
}
-#define dom_node_get_base(n, r) dom_node_get_base((dom_node *) (n), \
- (dom_string **) (r))
+#define dom_node_get_base(n, r) dom_node_get_base((dom_node *) (n), (r))
static inline dom_exception dom_node_compare_document_position(
struct dom_node *node, struct dom_node *other,
@@ -480,7 +473,7 @@ static inline dom_exception dom_node_get_text_content(struct dom_node *node,
(dom_node_internal *) node, result);
}
#define dom_node_get_text_content(n, r) dom_node_get_text_content( \
- (dom_node *) (n), (dom_string **) (r))
+ (dom_node *) (n), (r))
static inline dom_exception dom_node_set_text_content(struct dom_node *node,
dom_string *content)
@@ -489,7 +482,7 @@ static inline dom_exception dom_node_set_text_content(struct dom_node *node,
(dom_node_internal *) node, content);
}
#define dom_node_set_text_content(n, c) dom_node_get_text_content( \
- (dom_node *) (n), (dom_string *) (c))
+ (dom_node *) (n), (c))
static inline dom_exception dom_node_is_same(struct dom_node *node,
struct dom_node *other, bool *result)
@@ -509,8 +502,7 @@ static inline dom_exception dom_node_lookup_prefix(struct dom_node *node,
(dom_node_internal *) node, namespace, result);
}
#define dom_node_lookup_prefix(n, ns, r) dom_node_lookup_prefix( \
- (dom_node *) (n), (dom_string *) (ns), \
- (dom_string **) (r))
+ (dom_node *) (n), (ns), (r))
static inline dom_exception dom_node_is_default_namespace(
struct dom_node *node, dom_string *namespace,
@@ -521,7 +513,7 @@ static inline dom_exception dom_node_is_default_namespace(
(dom_node_internal *) node, namespace, result);
}
#define dom_node_is_default_namespace(n, ns, r) dom_node_is_default_namespace(\
- (dom_node *) (n), (dom_string *) (ns), (bool *) (r))
+ (dom_node *) (n), (ns), (bool *) (r))
static inline dom_exception dom_node_lookup_namespace(struct dom_node *node,
dom_string *prefix, dom_string **result)
@@ -530,8 +522,7 @@ static inline dom_exception dom_node_lookup_namespace(struct dom_node *node,
(dom_node_internal *) node, prefix, result);
}
#define dom_node_lookup_namespace(n, p, r) dom_node_lookup_namespace( \
- (dom_node *) (n), (dom_string *) (p), \
- (dom_string **) (r))
+ (dom_node *) (n), (p), (r))
static inline dom_exception dom_node_is_equal(struct dom_node *node,
struct dom_node *other, bool *result)
@@ -552,8 +543,7 @@ static inline dom_exception dom_node_get_feature(struct dom_node *node,
(dom_node_internal *) node, feature, version, result);
}
#define dom_node_get_feature(n, f, v, r) dom_node_get_feature( \
- (dom_node *) (n), (dom_string *) (f), \
- (dom_string *) (v), (void **) (r))
+ (dom_node *) (n), (f), (v), (void **) (r))
static inline dom_exception dom_node_set_user_data(struct dom_node *node,
dom_string *key, void *data,
@@ -564,7 +554,7 @@ static inline dom_exception dom_node_set_user_data(struct dom_node *node,
result);
}
#define dom_node_set_user_data(n, k, d, h, r) dom_node_set_user_data( \
- (dom_node *) (n), (dom_string *) (k), (void *) (d), \
+ (dom_node *) (n), (k), (void *) (d), \
(dom_user_data_handler) h, (void **) (r))
static inline dom_exception dom_node_get_user_data(struct dom_node *node,
@@ -574,6 +564,6 @@ static inline dom_exception dom_node_get_user_data(struct dom_node *node,
(dom_node_internal *) node, key, result);
}
#define dom_node_get_user_data(n, k, r) dom_node_get_user_data( \
- (dom_node *) (n), (dom_string *) (k), (void **) (r))
+ (dom_node *) (n), (k), (void **) (r))
#endif
diff --git a/include/dom/core/text.h b/include/dom/core/text.h
index 61e1c4c..1750aec 100644
--- a/include/dom/core/text.h
+++ b/include/dom/core/text.h
@@ -56,8 +56,7 @@ static inline dom_exception dom_text_get_whole_text(struct dom_text *text,
return ((dom_text_vtable *) ((dom_node *) text)->vtable)->
dom_text_get_whole_text(text, result);
}
-#define dom_text_get_whole_text(t, r) dom_text_get_whole_text((dom_text *) (t),\
- (dom_string **) (r))
+#define dom_text_get_whole_text(t, r) dom_text_get_whole_text((dom_text *) (t), (r))
static inline dom_exception dom_text_replace_whole_text(struct dom_text *text,
dom_string *content, struct dom_text **result)
@@ -66,6 +65,6 @@ static inline dom_exception dom_text_replace_whole_text(struct dom_text *text,
dom_text_replace_whole_text(text, content, result);
}
#define dom_text_replace_whole_text(t, c, r) dom_text_replace_whole_text( \
- (dom_text *) (t), (dom_string *) (c), (dom_text **) (r))
+ (dom_text *) (t), (c), (dom_text **) (r))
#endif
diff --git a/include/dom/core/typeinfo.h b/include/dom/core/typeinfo.h
index caa2094..6a6a9bc 100644
--- a/include/dom/core/typeinfo.h
+++ b/include/dom/core/typeinfo.h
@@ -25,22 +25,20 @@ typedef enum {
dom_exception _dom_type_info_get_type_name(dom_type_info *ti,
dom_string **ret);
#define dom_type_info_get_type_name(t, r) _dom_type_info_get_type_name( \
- (dom_type_info *) (t), (dom_string **) (r))
+ (dom_type_info *) (t), (r))
dom_exception _dom_type_info_get_type_namespace(dom_type_info *ti,
dom_string **ret);
#define dom_type_info_get_type_namespace(t, r) \
- _dom_type_info_get_type_namespace((dom_type_info *) (t),\
- (dom_string **) (r))
+ _dom_type_info_get_type_namespace((dom_type_info *) (t), (r))
dom_exception _dom_type_info_is_derived(dom_type_info *ti,
dom_string *namespace, dom_string *name,
dom_type_info_derivation_method method, bool *ret);
#define dom_type_info_is_derived(t, s, n, m, r) _dom_type_info_is_derived(\
- (dom_type_info *) (t), (dom_string *) (s), \
- (dom_string *) (n), \
+ (dom_type_info *) (t), (s), (n), \
(dom_type_info_derivation_method) (m), (bool *) (r))