Package ghidra.pcode.emu.jit.gen.util
Interface Check
public interface Check
Utility for explicitly checking the stack at a given point in a bytecode sequence.
-
Method Summary
-
Method Details
-
expect
Explicitly check the stack at this point in the bytecode sequenceThis is meant to be used with chosen type parameters, e.g.:
return em .emit(Op::ldc__i, 42) .emit(Check::<Ent<Bot, TInt>> expect);Granted, that's not a particularly complicated case warranting such a check, it demonstrates the idiom for placing the check. These are often only in place while the sequence is devised, and then removed.
- Type Parameters:
N- the expected stack- Parameters:
em- the emitter typed with the expected stack- Returns:
- the same emitter
-