Esempio n. 1
0
 private void ProcessJumpIf(ScriptBuilder sb)
 {
     if (Arguments.Length != 2)
     {
         throw new CompilerException(LineNumber, ERR_INCORRECT_NUMBER);
     }
     if (Arguments[0].IsRegister() && Arguments[1].IsLabel())
     {
         var reg   = Arguments[0].AsRegister();
         var label = Arguments[1].AsLabel();
         sb.EmitConditionalJump(this._opcode.Value, reg, label);
     }
     else
     {
         throw new CompilerException(LineNumber, ERR_INVALID_ARGUMENT);
     }
 }