@@ -510,7 +510,7 @@ class OverriddenInstructionPlaceHolder:
510
510
name : str
511
511
512
512
513
- AnyInstruction = Instruction | MacroInstruction
513
+ AnyInstruction = Instruction | MacroInstruction | PseudoInstruction
514
514
INSTR_FMT_PREFIX = "INSTR_FMT_"
515
515
INSTR_FLAG_SUFFIX = "_FLAG"
516
516
@@ -550,6 +550,7 @@ def error(self, msg: str, node: parser.Node) -> None:
550
550
macros : dict [str , parser .Macro ]
551
551
macro_instrs : dict [str , MacroInstruction ]
552
552
families : dict [str , parser .Family ]
553
+ pseudos : dict [str , parser .Pseudo ]
553
554
pseudo_instrs : dict [str , PseudoInstruction ]
554
555
555
556
def parse (self ) -> None :
@@ -607,7 +608,7 @@ def parse_file(self, filename: str, instrs_idx: dict[str, int]) -> None:
607
608
608
609
# Parse from start
609
610
psr .setpos (start )
610
- thing : parser .InstDef | parser .Macro | parser .Family | None
611
+ thing : parser .InstDef | parser .Macro | parser .Pseudo | parser . Family | None
611
612
thing_first_token = psr .peek ()
612
613
while thing := psr .definition ():
613
614
if ws := [w for w in RESERVED_WORDS if variable_used (thing , w )]:
@@ -927,7 +928,7 @@ def effect_str(effects: list[StackEffect]) -> str:
927
928
popped = str (- low )
928
929
pushed = str (sp - low )
929
930
case parser .Pseudo ():
930
- instr = self .pseudos [thing .name ]
931
+ instr = self .pseudo_instrs [thing .name ]
931
932
popped = pushed = None
932
933
# Calculate stack effect, and check that it's the the same
933
934
# for all targets.
0 commit comments