const css_qname *qname, void **sibling);
 static css_error named_generic_sibling_node(void *pw, void *node,
                const css_qname *qname, void **sibling);
+static css_error parent_node(void *pw, void *node, void **parent);
 
 
 /**
 
        return CSS_OK;
 }
+
+
+/**
+ * Return a pointer to the given node's parent
+ *
+ * \param pw      Pointer to the current SVG parser state
+ * \param node    Libdom SVG node
+ * \param parent  Address at which to store the node's parent pointer
+ *
+ * \return Always returns CSS_OK
+ */
+css_error parent_node(void *pw, void *node, void **parent)
+{
+       UNUSED(pw);
+       /* Libdom basically implements this for us */
+       dom_element_parent_node(node, (struct dom_element **)parent);
+
+       /* See the comment in named_parent_node() for why we decrement
+        * this reference counter here. */
+       dom_node_unref(*parent);
+
+       return CSS_OK;
+}