mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-10-22 15:38:23 +00:00
style: reduce scopes
* src/symlist.c (symbol_list_free): New.
This commit is contained in:
1 parent
d459a5b8e6
commit
48429252c1
1 file changed
+6
-7
+6
-7
@@ -148,14 +148,13 @@ symbol_list_append (symbol_list *list, symbol_list *node)
|
||||
void
|
||||
symbol_list_free (symbol_list *list)
|
||||
{
|
||||
symbol_list *node, *next;
|
||||
for (node = list; node; node = next)
|
||||
for (symbol_list *next; list; list = next)
|
||||
{
|
||||
next = node->next;
|
||||
named_ref_free (node->named_ref);
|
||||
if (node->content_type == SYMLIST_TYPE)
|
||||
free (node->content.sem_type);
|
||||
free (node);
|
||||
next = list->next;
|
||||
named_ref_free (list->named_ref);
|
||||
if (list->content_type == SYMLIST_TYPE)
|
||||
free (list->content.sem_type);
|
||||
free (list);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user