Add new SKIP range
git-svn-id: svn://svn.cc65.org/cc65/trunk@2412 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
@@ -238,8 +238,13 @@ static void OneOpcode (unsigned RemainingBytes)
|
||||
/* Get the opcode description for the opcode byte */
|
||||
const OpcDesc* D = &OpcTable[OPC];
|
||||
|
||||
/* If we have a label at this address, output the label */
|
||||
if (MustDefLabel (PC)) {
|
||||
/* Get the output style for the current PC */
|
||||
attr_t Style = GetStyleAttr (PC);
|
||||
|
||||
/* If we have a label at this address, output the label, provided that
|
||||
* we aren't in a skip area.
|
||||
*/
|
||||
if (Style != atSkip && MustDefLabel (PC)) {
|
||||
DefLabel (GetLabel (PC));
|
||||
}
|
||||
|
||||
@@ -249,7 +254,7 @@ static void OneOpcode (unsigned RemainingBytes)
|
||||
* - ...if there is no label somewhere between the instruction bytes.
|
||||
* If any of these conditions is false, switch to data mode.
|
||||
*/
|
||||
if (GetStyleAttr (PC) == atDefault) {
|
||||
if (Style == atDefault) {
|
||||
if (D->Size > RemainingBytes) {
|
||||
MarkAddr (PC, atIllegal);
|
||||
} else if (D->Flags & flIllegal) {
|
||||
@@ -257,16 +262,16 @@ static void OneOpcode (unsigned RemainingBytes)
|
||||
} else {
|
||||
unsigned I;
|
||||
for (I = 1; I < D->Size; ++I) {
|
||||
if (HaveLabel (PC+I)) {
|
||||
MarkAddr (PC, atIllegal);
|
||||
break;
|
||||
}
|
||||
if (HaveLabel (PC+I)) {
|
||||
MarkAddr (PC, atIllegal);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* Disassemble the line */
|
||||
switch (GetStyleAttr (PC)) {
|
||||
switch (Style) {
|
||||
|
||||
case atDefault:
|
||||
case atCode:
|
||||
@@ -293,7 +298,7 @@ static void OneOpcode (unsigned RemainingBytes)
|
||||
case atAddrTab:
|
||||
AddrTable ();
|
||||
break;
|
||||
|
||||
|
||||
case atRtsTab:
|
||||
RtsTable ();
|
||||
break;
|
||||
@@ -302,6 +307,10 @@ static void OneOpcode (unsigned RemainingBytes)
|
||||
TextTable ();
|
||||
break;
|
||||
|
||||
case atSkip:
|
||||
++PC;
|
||||
break;
|
||||
|
||||
default:
|
||||
DataByteLine (1);
|
||||
++PC;
|
||||
|
||||
Reference in New Issue
Block a user