summaryrefslogtreecommitdiff
path: root/src/lcode.js
diff options
context:
space:
mode:
authorBenoit Giannangeli <benoit.giannangeli@boursorama.fr>2017-02-28 11:29:37 +0100
committerBenoit Giannangeli <benoit.giannangeli@boursorama.fr>2017-02-28 11:29:37 +0100
commit8d576081a53ee1a866491b423c5373951aa6a7c4 (patch)
treeeeecaba0f1e542b4bc830ce103b3678893a7cd42 /src/lcode.js
parentf37df0022d609443c5b3f222a85ee465d8211b88 (diff)
downloadfengari-8d576081a53ee1a866491b423c5373951aa6a7c4.tar.gz
fengari-8d576081a53ee1a866491b423c5373951aa6a7c4.tar.bz2
fengari-8d576081a53ee1a866491b423c5373951aa6a7c4.zip
jshint
Diffstat (limited to 'src/lcode.js')
-rw-r--r--src/lcode.js9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/lcode.js b/src/lcode.js
index e64c0a9..9a5cda0 100644
--- a/src/lcode.js
+++ b/src/lcode.js
@@ -1,4 +1,3 @@
-/* jshint esversion: 6 */
"use strict";
const assert = require('assert');
@@ -203,7 +202,7 @@ const luaK_patchclose = function(fs, list, level) {
level++; /* argument is +1 to reserve 0 as non-op */
for (; list !== NO_JUMP; list = getjump(fs, list)) {
let ins = fs.f.code[list];
- assert(ins.opcode === OpCodesI.OP_JMP && (ins.A === 0 || i.A >= level);
+ assert(ins.opcode === OpCodesI.OP_JMP && (ins.A === 0 || ins.A >= level));
lopcode.SETARG_A(ins, level);
}
};
@@ -237,9 +236,9 @@ const luaK_codeABC = function(fs, o, a, b, c) {
** Format and emit an 'iABx' instruction.
*/
const luaK_codeABx = function(fs, o, a, bc) {
- lua_assert(lopcode.getOpMode(o) == lopcode.iABx || getOpMode(o) == lopcode.iAsBx);
- lua_assert(lopcode.getCMode(o) == lopcode.OpArgN);
- lua_assert(a <= lopcode.MAXARG_A && bc <= lopcode.MAXARG_Bx);
+ assert(lopcode.getOpMode(o) == lopcode.iABx || lopcode.getOpMode(o) == lopcode.iAsBx);
+ assert(lopcode.getCMode(o) == lopcode.OpArgN);
+ assert(a <= lopcode.MAXARG_A && bc <= lopcode.MAXARG_Bx);
return luaK_code(fs, lopcode.CREATE_ABx(o, a, bc));
};