Fixed exports for now
git-svn-id: svn://svn.cc65.org/cc65/trunk@2628 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
@@ -705,7 +705,7 @@ void WriteImports (void)
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
static unsigned char GetExprMask (SymEntry* S)
|
static unsigned char GetExportExprMask (SymEntry* S)
|
||||||
/* Return the expression bits for the given symbol table entry */
|
/* Return the expression bits for the given symbol table entry */
|
||||||
{
|
{
|
||||||
unsigned char ExprMask;
|
unsigned char ExprMask;
|
||||||
@@ -714,7 +714,7 @@ static unsigned char GetExprMask (SymEntry* S)
|
|||||||
ExprMask = (SymIsConst (S))? EXP_CONST : EXP_EXPR;
|
ExprMask = (SymIsConst (S))? EXP_CONST : EXP_EXPR;
|
||||||
|
|
||||||
/* Add zeropage/abs bits */
|
/* Add zeropage/abs bits */
|
||||||
ExprMask |= (S->AddrSize == ADDR_SIZE_ZP)? EXP_ZP : EXP_ABS;
|
ExprMask |= (S->ExportSize == ADDR_SIZE_ZP)? EXP_ZP : EXP_ABS;
|
||||||
|
|
||||||
/* Add the label/equate bits */
|
/* Add the label/equate bits */
|
||||||
ExprMask |= (S->Flags & SF_LABEL)? EXP_LABEL : EXP_EQUATE;
|
ExprMask |= (S->Flags & SF_LABEL)? EXP_LABEL : EXP_EQUATE;
|
||||||
@@ -747,7 +747,7 @@ void WriteExports (void)
|
|||||||
SymFinalize (S);
|
SymFinalize (S);
|
||||||
|
|
||||||
/* Get the expression bits */
|
/* Get the expression bits */
|
||||||
ExprMask = GetExprMask (S);
|
ExprMask = GetExportExprMask (S);
|
||||||
|
|
||||||
/* Count the number of ConDes types */
|
/* Count the number of ConDes types */
|
||||||
for (Type = 0; Type < CD_TYPE_COUNT; ++Type) {
|
for (Type = 0; Type < CD_TYPE_COUNT; ++Type) {
|
||||||
@@ -793,6 +793,26 @@ void WriteExports (void)
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
static unsigned char GetDbgExprMask (SymEntry* S)
|
||||||
|
/* Return the expression bits for the given symbol table entry */
|
||||||
|
{
|
||||||
|
unsigned char ExprMask;
|
||||||
|
|
||||||
|
/* Check if the symbol is const */
|
||||||
|
ExprMask = (SymIsConst (S))? EXP_CONST : EXP_EXPR;
|
||||||
|
|
||||||
|
/* Add zeropage/abs bits */
|
||||||
|
ExprMask |= (S->AddrSize == ADDR_SIZE_ZP)? EXP_ZP : EXP_ABS;
|
||||||
|
|
||||||
|
/* Add the label/equate bits */
|
||||||
|
ExprMask |= (S->Flags & SF_LABEL)? EXP_LABEL : EXP_EQUATE;
|
||||||
|
|
||||||
|
/* Return the mask */
|
||||||
|
return ExprMask;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
void WriteDbgSyms (void)
|
void WriteDbgSyms (void)
|
||||||
/* Write a list of all symbols to the object file */
|
/* Write a list of all symbols to the object file */
|
||||||
{
|
{
|
||||||
@@ -828,7 +848,7 @@ void WriteDbgSyms (void)
|
|||||||
SymFinalize (S);
|
SymFinalize (S);
|
||||||
|
|
||||||
/* Get the expression bits */
|
/* Get the expression bits */
|
||||||
ExprMask = GetExprMask (S);
|
ExprMask = GetDbgExprMask (S);
|
||||||
|
|
||||||
/* Write the type */
|
/* Write the type */
|
||||||
ObjWrite8 (ExprMask);
|
ObjWrite8 (ExprMask);
|
||||||
|
|||||||
Reference in New Issue
Block a user