api doc and minor changes
[protos/libecoli.git] / src / ecoli_node_space.c
index 761ed76..ff7ca14 100644 (file)
 EC_LOG_TYPE_REGISTER(node_space);
 
 struct ec_node_space {
-       struct ec_node gen;
 };
 
 static int
-ec_node_space_parse(const struct ec_node *gen_node,
-               struct ec_parse *state,
+ec_node_space_parse(const struct ec_node *node,
+               struct ec_pnode *pstate,
                const struct ec_strvec *strvec)
 {
        const char *str;
        size_t len = 0;
 
-       (void)state;
-       (void)gen_node;
+       (void)pstate;
+       (void)node;
 
        if (ec_strvec_len(strvec) == 0)
                return EC_PARSE_NOMATCH;
@@ -48,7 +47,6 @@ ec_node_space_parse(const struct ec_node *gen_node,
 static struct ec_node_type ec_node_space_type = {
        .name = "space",
        .parse = ec_node_space_parse,
-       .complete = ec_node_complete_unknown,
        .size = sizeof(struct ec_node_space),
 };
 
@@ -80,14 +78,14 @@ static int ec_node_space_testcase(void)
        }
        /* never completes whatever the input */
        testres |= EC_TEST_CHECK_COMPLETE(node,
-               "", EC_NODE_ENDLIST,
-               EC_NODE_ENDLIST);
+               "", EC_VA_END,
+               EC_VA_END);
        testres |= EC_TEST_CHECK_COMPLETE(node,
-               " ", EC_NODE_ENDLIST,
-               EC_NODE_ENDLIST);
+               " ", EC_VA_END,
+               EC_VA_END);
        testres |= EC_TEST_CHECK_COMPLETE(node,
-               "foo", EC_NODE_ENDLIST,
-               EC_NODE_ENDLIST);
+               "foo", EC_VA_END,
+               EC_VA_END);
        ec_node_free(node);
 
        return testres;