List of all members.
Public Member Functions |
| CMacro (CSymbol *aSymbol, Coord_t *aLoc) |
| Create a macro declaration object.
|
virtual CDecl * | Clone (CObstack *heap) |
| Create a clone of this declaration.
|
char * | GetBody (void) |
| Get body of macro.
|
void | SetBody (char *aBody) |
| Set body of macro.
|
int | GetZone (void) |
| Get preprocessor zone number for last macro definition.
|
void | SetZone (int aZone) |
| Set preprocessor zone number.
|
void | SetComplex (int aComplex) |
| Set complex flag.
|
int | IsComplex (void) |
| Get complex flag.
|
char ** | GetArgList (void) |
| Get macro arguments.
|
void | SetArgList (char **argList) |
| Set macro arguments.
|
virtual void | Dump (FILE *f) |
| Dump macro info to file descriptor.
|
int | IsDefined (void) |
| Get defined flag.
|
void | SetDefined (int aDefined) |
| Set defined flag.
|
Static Public Member Functions |
static CMacro * | LookupMacro (const char *aName) |
| Find macro definition.
|
Protected Member Functions |
void | Copy (CObstack *heap, CMacro &d) |
| Deep copy of declaration.
|
Detailed Description
Declaration object for preprocessor macros.
Constructor & Destructor Documentation
Create a macro declaration object.
- Parameters:
-
| aSymbol | name of macro. |
| aLoc | file coordinate of definition. |
Member Function Documentation
Create a clone of this declaration.
- Parameters:
-
| heap | heap to use for allocation. |
- Returns:
- new declaration.
Implements CDecl.
Deep copy of declaration.
- Parameters:
-
| heap | heap to use for allocation. |
| d | declaration to copy. |
virtual void CMacro::Dump |
( |
FILE * |
f |
) |
[virtual] |
Dump macro info to file descriptor.
- Parameters:
-
Reimplemented from CDecl.
char** CMacro::GetArgList |
( |
void |
|
) |
|
Get macro arguments.
- Returns:
- pointer to array of macro arguments.
char* CMacro::GetBody |
( |
void |
|
) |
|
Get body of macro.
- Returns:
- macro body.
int CMacro::GetZone |
( |
void |
|
) |
[inline] |
Get preprocessor zone number for last macro definition.
- Returns:
- preprocessor zone number.
int CMacro::IsComplex |
( |
void |
|
) |
|
Get complex flag.
- Returns:
- non-zero if macro has arguments.
int CMacro::IsDefined |
( |
void |
|
) |
|
Get defined flag.
- Returns:
- non-zero if macro has been defined.
static CMacro* CMacro::LookupMacro |
( |
const char * |
aName |
) |
[static] |
Find macro definition.
Create an undefined entry if it doesn't exist.
- Parameters:
-
| aName | char pointer to macro name. |
- Returns:
- macro object.
void CMacro::SetArgList |
( |
char ** |
argList |
) |
|
Set macro arguments.
- Parameters:
-
| argList | pointer to array of macro arguments. Array is not copied. |
void CMacro::SetBody |
( |
char * |
aBody |
) |
|
Set body of macro.
- Parameters:
-
void CMacro::SetComplex |
( |
int |
aComplex |
) |
|
Set complex flag.
- Parameters:
-
| aComplex | non-zero if macro has arguments. |
void CMacro::SetDefined |
( |
int |
aDefined |
) |
|
Set defined flag.
- Parameters:
-
| aDefined | non-zero if macro has been defined. |
void CMacro::SetZone |
( |
int |
aZone |
) |
[inline] |
Set preprocessor zone number.
- Parameters:
-
| aZone | preprocessor zone number. |
The documentation for this class was generated from the following file:
- /net/fileserver/nas/home/mdh/vrq/src/cmacro.h