summaryrefslogtreecommitdiff
path: root/src/node.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/node.c')
-rw-r--r--src/node.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/node.c b/src/node.c
index 243c3e6..674f988 100644
--- a/src/node.c
+++ b/src/node.c
@@ -84,6 +84,17 @@ cmark_node_get_type(cmark_node *node)
}
}
+int
+cmark_node_set_type(cmark_node *node, cmark_node_type node_type)
+{
+ if (node == NULL) {
+ return 0;
+ } else {
+ node->type = node_type;
+ return 1;
+ }
+}
+
static const char*
S_type_string(cmark_node *node)
{