C Cross Referencing & Documentation tool. Version 1.6e.
Collects the typedef stuff.
Control the output of debugging information in this file.
The file that is currently being processed.
extern File CurFile
Defined in: | cxref.c |
Whether we are parsing a typedef or not.
extern int in_typedef
Defined in: | parse-yacc.c |
The defined types that we have seen.
Used in: | IsATypeName() | |
ResetTypeAnalyser() | ||
SeenTypedefName() |
The current struct / union or enum definition.
Used in: | ResetTypeAnalyser() | |
SeenStructUnionComp() | ||
SeenStructUnionEnd() | ||
SeenStructUnionStart() |
The current struct / union if seen in a typedef.
static StructUnion cur_type_su
Used in: | ResetTypeAnalyser() | |
SeenStructUnionEnd() | ||
SeenTypedef() |
The last typedef seen, used when two types share a typedef statement.
Used in: | ResetTypeAnalyser() | |
SeenTypedef() |
The line number that a typedef or structure was seen on.
Used in: | SeenStructUnionEnd() | |
SeenStructUnionStart() | ||
SeenTypedef() |
Delete the specified Typedef type.
void DeleteTypedefType ( Typedef type )
Prototyped in: | cxref.h | |
Calls: | DeleteStructUnionType() | type.c |
SafeFree() | memory.c | |
Called by: | DeleteFile() | file.c |
Function that is called when an IDENTIFIER is seen in the current file, it may be a defined type.
int IsATypeName ( char* name )
Prototyped in: | cxref.h | |
Calls: | strcmp() | |
Called by: | yylex() | parse-lex.c |
yyparse() | parse-yacc.c | |
References Variables: | typedefs | type.c |
Tidy up all of the local variables in case of a problem and abnormal parser termination.
void ResetTypeAnalyser ( void )
Prototyped in: | cxref.h | |
Calls: | DeleteStringList2() | slist.c |
DeleteStructUnionType() | type.c | |
Called by: | main() | cxref.c |
References Variables: | cur_su | type.c |
cur_type_su | type.c | |
last_typedef | type.c | |
typedefs | type.c |
Function called when a component of a struct / union / enum is seen.
void SeenStructUnionComp ( char* name, int depth )
Prototyped in: | cxref.h | |
Calls: | ConcatStrings() | memory.c |
CopyStructUnion() | type.c | |
GetCurrentComment() | comment.c | |
NewStructUnionType() | type.c | |
NewTypedefType() | type.c | |
SafeFree() | memory.c | |
SafeMalloc() | memory.c | |
SafeMallocString() | memory.c | |
SafeRealloc() | memory.c | |
strchr(), strcmp() | ||
Called by: | yyparse() | parse-yacc.c |
References Variables: | CurFile | cxref.c |
cur_su | type.c | |
parse_line | parse-lex.c |
Function that is called when the end of a struct or union or enum definition is seen.
void SeenStructUnionEnd ( void )
Prototyped in: | cxref.h | |
Calls: | NewTypedefType() | type.c |
strlen(), strncmp() | ||
Called by: | yyparse() | parse-yacc.c |
References Variables: | CurFile | cxref.c |
cur_su | type.c | |
cur_type_su | type.c | |
in_typedef | parse-yacc.c | |
type_lineno | type.c |
Function that is called when the start of a struct or union or enum definition is seen.
void SeenStructUnionStart ( char* name )
Prototyped in: | cxref.h | |
Calls: | DeleteStructUnionType() | type.c |
GetCurrentComment() | comment.c | |
NewStructUnionType() | type.c | |
SafeMallocString() | memory.c | |
Called by: | yyparse() | parse-yacc.c |
References Variables: | cur_su | type.c |
in_typedef | parse-yacc.c | |
parse_line | parse-lex.c | |
type_lineno | type.c |
Function that is called when a typedef is seen in the current file. This is recorded fully for later output.
void SeenTypedef ( char* name, char* type )
Prototyped in: | cxref.h | |
Calls: | GetCurrentComment() | comment.c |
NewTypedefType() | type.c | |
SafeMallocString() | memory.c | |
strlen(), strncmp() | ||
Called by: | yyparse() | parse-yacc.c |
References Variables: | CurFile | cxref.c |
cur_type_su | type.c | |
last_typedef | type.c | |
parse_line | parse-lex.c | |
type_lineno | type.c |
Function that is called when a typedef is seen in the current file. The name of the typedef is stored for future reference.
void SeenTypedefName ( char* name, int what_type )
Prototyped in: | cxref.h | |
Calls: | AddToStringList2() | slist.c |
NewStringList2() | slist.c | |
Called by: | yyparse() | parse-yacc.c |
References Variables: | typedefs | type.c |
Make a copy of the specified Struct / Union structure.
static StructUnion CopyStructUnion ( StructUnion su )
This needs to call itself recursively.
Prototyped in: | type.c | |
Calls: | CopyStructUnion() | type.c |
NewStructUnionType() | type.c | |
SafeMalloc() | memory.c | |
SafeMallocString() | memory.c | |
Called by: | CopyStructUnion() | type.c |
SeenStructUnionComp() | type.c |
Free the memory associated with a Struct / Union structure.
static void DeleteStructUnionType ( StructUnion su )
This needs to call itself recursively.
Prototyped in: | type.c | |
Calls: | DeleteStructUnionType() | type.c |
SafeFree() | memory.c | |
Called by: | DeleteStructUnionType() | type.c |
DeleteTypedefType() | type.c | |
ResetTypeAnalyser() | type.c | |
SeenStructUnionStart() | type.c |
Create a new struct / union type.
static StructUnion NewStructUnionType ( char* name )
Prototyped in: | type.c | |
Calls: | SafeCalloc() | memory.c |
SafeMallocString() | memory.c | |
Called by: | CopyStructUnion() | type.c |
SeenStructUnionComp() | type.c | |
SeenStructUnionStart() | type.c |
Create a new Typedef type.
static Typedef NewTypedefType ( char* name, char* type )
Prototyped in: | type.c | |
Calls: | SafeCalloc() | memory.c |
SafeMallocString() | memory.c | |
Called by: | SeenStructUnionComp() | type.c |
SeenStructUnionEnd() | type.c | |
SeenTypedef() | type.c |