Remove build_empty_property(). It wasn't useful.
parent
81f2e89c75
commit
9ad4587c90
|
@ -88,7 +88,7 @@ propdef: label DT_PROPNAME '=' propdata ';' {
|
|||
$$ = build_property($2, $4, $1);
|
||||
}
|
||||
| label DT_PROPNAME ';' {
|
||||
$$ = build_empty_property($2, $1);
|
||||
$$ = build_property($2, empty_data, $1);
|
||||
}
|
||||
;
|
||||
|
||||
|
|
1
dtc.h
1
dtc.h
|
@ -156,7 +156,6 @@ struct node {
|
|||
for ((c) = (n)->children; (c); (c) = (c)->next_sibling)
|
||||
|
||||
struct property *build_property(char *name, struct data val, char *label);
|
||||
struct property *build_empty_property(char *name, char *label);
|
||||
struct property *chain_property(struct property *first, struct property *list);
|
||||
|
||||
struct node *build_node(struct property *proplist, struct node *children);
|
||||
|
|
13
livetree.c
13
livetree.c
|
@ -38,19 +38,6 @@ struct property *build_property(char *name, struct data val, char *label)
|
|||
return new;
|
||||
}
|
||||
|
||||
struct property *build_empty_property(char *name, char *label)
|
||||
{
|
||||
struct property *new = xmalloc(sizeof(*new));
|
||||
|
||||
new->name = name;
|
||||
new->val = empty_data;
|
||||
new->next = NULL;
|
||||
|
||||
new->label = label;
|
||||
|
||||
return new;
|
||||
}
|
||||
|
||||
struct property *chain_property(struct property *first, struct property *list)
|
||||
{
|
||||
assert(first->next == NULL);
|
||||
|
|
Loading…
Reference in New Issue