Working on better 65816 support
git-svn-id: svn://svn.cc65.org/cc65/trunk@2619 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
@@ -917,7 +917,7 @@ ExprNode* GenCurrentPC (void)
|
||||
if (RelocMode) {
|
||||
/* Create SegmentBase + Offset */
|
||||
Root = NewExprNode (EXPR_PLUS);
|
||||
Root->Left = GenSectionExpr (GetSegNum ());
|
||||
Root->Left = GenSectionExpr (GetCurrentSegNum ());
|
||||
Root->Right = GenLiteralExpr (GetPC ());
|
||||
} else {
|
||||
/* Absolute mode, just return PC value */
|
||||
@@ -950,7 +950,7 @@ ExprNode* GenBranchExpr (unsigned Offs)
|
||||
/* Create *+Offs */
|
||||
if (RelocMode) {
|
||||
N = NewExprNode (EXPR_PLUS);
|
||||
N->Left = GenSectionExpr (GetSegNum ());
|
||||
N->Left = GenSectionExpr (GetCurrentSegNum ());
|
||||
N->Right = GenLiteralExpr (GetPC () + Offs);
|
||||
} else {
|
||||
N = GenLiteralExpr (GetPC () + Offs);
|
||||
@@ -1120,7 +1120,7 @@ static void CheckByteExpr (const ExprNode* N, int* IsByte)
|
||||
break;
|
||||
|
||||
case EXPR_SECTION:
|
||||
if (GetSegType (N->V.SegNum) == SEGTYPE_ZP) {
|
||||
if (GetSegAddrSize (N->V.SegNum) == ADDR_SIZE_ZP) {
|
||||
*IsByte = 1;
|
||||
}
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user