CFref Class Reference
Forward reference declaration.
More...
#include <cfref.h>
List of all members.
Detailed Description
Forward reference declaration.
This class should only be used by the parser and should never appear in or be created by plugins.
Constructor & Destructor Documentation
Create a forward reference.
- Parameters:
-
| symbol | declarations symbol. |
| aLoc | file coordinates. |
Member Function Documentation
virtual CDecl* CFref::Clone |
( |
CObstack * |
heap |
) |
[inline, virtual] |
Create a clone of this declaration.
- Parameters:
-
| heap | heap to use for allocation. |
- Returns:
- new declaration.
Implements CDecl.
void CFref::ConstrainTypes |
( |
list< Decl_t > & |
aTypes |
) |
[inline] |
Add a constraint on valid types for this declaration.
Note eNONE must always be in type list.
- Parameters:
-
| aTypes | list of valid types (must incude eNONE). |
void CFref::Direction |
( |
Decl_t |
d |
) |
[inline] |
Set direction of declaration.
- Parameters:
-
Decl_t CFref::Direction |
( |
|
) |
[inline] |
Get direction of declaration.
- Returns:
- d direction type.
virtual void CFref::Dump |
( |
FILE * |
f |
) |
[virtual] |
Dump declaration info to file descriptor.
- Parameters:
-
Reimplemented from CDecl.
CDecl* CFref::GetDecl |
( |
void |
|
) |
|
Get forward reference's actual declaration.
- Returns:
- actual declaration, NULL if not assigned.
CNode* CFref::GetLsb |
( |
void |
|
) |
[virtual] |
Get lsb of vector range.
- Returns:
- lsb expression, NULL if scalar.
Reimplemented from CDecl.
CNode* CFref::GetMsb |
( |
void |
|
) |
[virtual] |
Get msb of vector range.
- Returns:
- msb expression, NULL if scalar.
Reimplemented from CDecl.
virtual CNode* CFref::GetRange |
( |
|
) |
[virtual] |
Get expression for declaration's range (msb/lsb).
- Returns:
- range expression, NULL if scalar.
int CFref::IndicesRangeValid |
( |
|
) |
|
Determine if range can be inferred.
- Returns:
- non-zero if range can be inferred.
int CFref::IsArray |
( |
|
) |
[inline] |
Get array flag.
- Returns:
- non-zero if decl is an array.
void CFref::IsArray |
( |
int |
v |
) |
[inline] |
Set array flag.
- Parameters:
-
| v | non-zero if decl is an array. |
int CFref::IsTypeValid |
( |
Decl_t |
t |
) |
[inline] |
Test if a give declaration type is valid for this reference.
- Parameters:
-
| t | declaration type to test for. |
- Returns:
- non-zero if type is compatable with constraints.
int CFref::Lval |
( |
|
) |
[inline] |
Get lval flag.
- Returns:
- non-zero if decl has been used as an lval.
void CFref::Lval |
( |
int |
aLval |
) |
[inline] |
Set lval flag.
- Parameters:
-
| aLval | non-zero means decl has been used as an lval. |
void CFref::SetDecl |
( |
CDecl * |
aDecl |
) |
|
Set forward declaration's actual declaration.
- Parameters:
-
| aDecl | actual declaration for forward reference. |
void CFref::SetRangeInfo |
( |
int |
isArray, |
|
|
CNode * |
range | |
|
) |
| | |
Set range info for declaration.
- Parameters:
-
| isArray | non-zero if declaration is an array. |
| range | vector range expression. |
The documentation for this class was generated from the following file:
- /net/fileserver/nas/home/mdh/vrq/src/cfref.h