コード例 #1
0
ファイル: lcode.c プロジェクト: OLR-xray/XRay-NEW
static void removevalues (FuncState *fs, int list) {
  for (; list != NO_JUMP; list = getjump(fs, list)) {
    Instruction *i = getjumpcontrol(fs, list);
    if (GET_OPCODE(*i) == OP_TESTSET)
      patchtestreg(i, NO_REG);
  }
}
コード例 #2
0
ファイル: lcode.c プロジェクト: AlvyPiper/lua-flex
static void patchlistaux (FuncState *fs, int list, int vtarget, int reg, int dtarget) {
    while (list != NO_JUMP) {
        int next = getjump(fs, list);
        if (patchtestreg(fs, list, reg))
            fixjump(fs, list, vtarget);
        else
            fixjump(fs, list, dtarget);    /* jump to default target */
        list = next;
    }
}
コード例 #3
0
ファイル: lcode.c プロジェクト: OLR-xray/XRay-NEW
static void patchlistaux (FuncState *fs, int list, int vtarget, int reg,
                          int dtarget) {
  while (list != NO_JUMP) {
    int next = getjump(fs, list);
    Instruction *i = getjumpcontrol(fs, list);
    if (GET_OPCODE(*i) == OP_TESTSET) {
      patchtestreg(i, reg);
      fixjump(fs, list, vtarget);
    }
    else
      fixjump(fs, list, dtarget);  /* jump to default target */
    list = next;
  }
}
コード例 #4
0
ファイル: lcode.c プロジェクト: yuanxiubin1128/mmo-resourse
static void luaK_patchlistaux (FuncState *fs, int list,
          int ttarget, int treg, int ftarget, int freg, int dtarget) {
  while (list != NO_JUMP) {
    int next = luaK_getjump(fs, list);
    Instruction *i = getjumpcontrol(fs, list);
    if (GET_OPCODE(*i) != OP_TEST) {
      lua_assert(dtarget != NO_JUMP);
      luaK_fixjump(fs, list, dtarget);  /* jump to default target */
    }
    else {
      if (GETARG_C(*i)) {
        lua_assert(ttarget != NO_JUMP);
        patchtestreg(i, treg);
        luaK_fixjump(fs, list, ttarget);
      }
      else {
        lua_assert(ftarget != NO_JUMP);
        patchtestreg(i, freg);
        luaK_fixjump(fs, list, ftarget);
      }
    }
    list = next;
  }
}
コード例 #5
0
ファイル: lcode.c プロジェクト: celskeggs/selkie
/*
** Traverse a list of tests ensuring no one produces a value
*/
static void removevalues (FuncState *fs, int list) {
  for (; list != NO_JUMP; list = getjump(fs, list))
      patchtestreg(fs, list, NO_REG);
}
コード例 #6
0
ファイル: lcode.cpp プロジェクト: swizl/lua
/*static*/ void FuncState::removevalues (/*FuncState *fs,*/ int list) {
	for (; list != NO_JUMP; list = getjump(list))
			patchtestreg(list, NO_REG);
}