Create separate extetnd.c file for handling extensions / %extend

This is just a simple code refactor, moving and function renaming to
remove the %extend code out of the parser into its own file now
 that it isn't just used in the parser.
This commit is contained in:
William S Fulton 2014-05-21 19:16:15 +01:00
commit 71e72c45ed
8 changed files with 205 additions and 158 deletions

View file

@ -88,3 +88,17 @@ void cparse_normalize_void(Node *n) {
}
}
}
/* -----------------------------------------------------------------------------
* new_node()
*
* Create an empty parse node, setting file and line number information
* ----------------------------------------------------------------------------- */
Node *new_node(const_String_or_char_ptr tag) {
Node *n = NewHash();
set_nodeType(n,tag);
Setfile(n,cparse_file);
Setline(n,cparse_line);
return n;
}