mirror of
https://github.com/cc65/cc65.git
synced 2024-12-25 02:29:52 +00:00
Changed freeing symbol relations, cosmetic changes
git-svn-id: svn://svn.cc65.org/cc65/trunk@2610 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
parent
b34d2df08b
commit
5881a2b4f5
@ -111,6 +111,11 @@ static void FreeExprNode (ExprNode* E)
|
||||
/* Free a node */
|
||||
{
|
||||
if (E) {
|
||||
if (E->Op == EXPR_SYMBOL) {
|
||||
/* Remove the symbol reference */
|
||||
SymDelRef (E->V.Sym, E);
|
||||
}
|
||||
/* Place the symbol into the free nodes list if possible */
|
||||
if (FreeNodeCount < MAX_FREE_NODES) {
|
||||
/* Remember this node for later */
|
||||
E->Left = FreeExprNodes;
|
||||
@ -951,10 +956,6 @@ void FreeExpr (ExprNode* Root)
|
||||
if (Root) {
|
||||
FreeExpr (Root->Left);
|
||||
FreeExpr (Root->Right);
|
||||
if (Root->Op == EXPR_SYMBOL) {
|
||||
/* Remove the symbol reference */
|
||||
SymDelRef (Root->V.Sym, Root);
|
||||
}
|
||||
FreeExprNode (Root);
|
||||
}
|
||||
}
|
||||
|
@ -59,7 +59,7 @@ struct Fragment {
|
||||
unsigned short Len; /* Length for this fragment */
|
||||
unsigned char Type; /* Fragment type */
|
||||
union {
|
||||
unsigned char Data [4]; /* Literal values */
|
||||
unsigned char Data[4]; /* Literal values */
|
||||
ExprNode* Expr; /* Expression */
|
||||
} V;
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user