mirror of
https://github.com/cc65/cc65.git
synced 2025-01-01 03:30:20 +00:00
Move local variable declaration to top of block
This commit is contained in:
parent
92bfbeb8ab
commit
1f6bc6240f
@ -317,6 +317,8 @@ void ParaVirtInit (unsigned aArgStart, unsigned char aSPAddr)
|
|||||||
void ParaVirtHooks (CPURegs* Regs)
|
void ParaVirtHooks (CPURegs* Regs)
|
||||||
/* Potentially execute paravirtualization hooks */
|
/* Potentially execute paravirtualization hooks */
|
||||||
{
|
{
|
||||||
|
unsigned lo;
|
||||||
|
|
||||||
/* Check for paravirtualization address range */
|
/* Check for paravirtualization address range */
|
||||||
if (Regs->PC < PARAVIRT_BASE ||
|
if (Regs->PC < PARAVIRT_BASE ||
|
||||||
Regs->PC >= PARAVIRT_BASE + sizeof (Hooks) / sizeof (Hooks[0])) {
|
Regs->PC >= PARAVIRT_BASE + sizeof (Hooks) / sizeof (Hooks[0])) {
|
||||||
@ -327,6 +329,6 @@ void ParaVirtHooks (CPURegs* Regs)
|
|||||||
Hooks[Regs->PC - PARAVIRT_BASE] (Regs);
|
Hooks[Regs->PC - PARAVIRT_BASE] (Regs);
|
||||||
|
|
||||||
/* Simulate RTS */
|
/* Simulate RTS */
|
||||||
unsigned lo = Pop(Regs);
|
lo = Pop(Regs);
|
||||||
Regs->PC = lo + (Pop(Regs) << 8) + 1;
|
Regs->PC = lo + (Pop(Regs) << 8) + 1;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user