aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordaurnimator <quae@daurnimator.com>2018-03-04 22:52:09 +1100
committerdaurnimator <quae@daurnimator.com>2018-03-04 22:52:09 +1100
commit80555ae8258b29b7cd72301a8dac81a10f2a7eeb (patch)
tree2afdde7fc4b7dda40e74aba862f1101091101eed
parent1f5f050ada93ccda9323209e2a7b29851392404e (diff)
downloadfengari-80555ae8258b29b7cd72301a8dac81a10f2a7eeb.tar.gz
fengari-80555ae8258b29b7cd72301a8dac81a10f2a7eeb.tar.bz2
fengari-80555ae8258b29b7cd72301a8dac81a10f2a7eeb.zip
Remove unwanted TODOs
-rw-r--r--src/lapi.js4
-rw-r--r--src/lbaselib.js1
-rw-r--r--src/ldo.js2
-rw-r--r--src/llex.js2
-rw-r--r--src/loadlib.js1
-rw-r--r--src/loslib.js1
6 files changed, 3 insertions, 8 deletions
diff --git a/src/lapi.js b/src/lapi.js
index 21b6c0d..b011cda 100644
--- a/src/lapi.js
+++ b/src/lapi.js
@@ -900,7 +900,7 @@ const lua_islightuserdata = function(L, idx) {
const lua_rawequal = function(L, index1, index2) {
let o1 = index2addr(L, index1);
let o2 = index2addr(L, index2);
- return isvalid(o1) && isvalid(o2) ? lvm.luaV_equalobj(null, o1, o2) : 0; // TODO: isvalid ?
+ return isvalid(o1) && isvalid(o2) ? lvm.luaV_equalobj(null, o1, o2) : 0;
};
const lua_arith = function(L, op) {
@@ -996,8 +996,6 @@ const lua_pcallk = function(L, nargs, nresults, errfunc, ctx, k) {
if (errfunc === 0)
func = 0;
else {
- // let o = index2addr(L, errfunc);
- // TODO: api_checkstackindex(L, errfunc, o);
func = index2addr_(L, errfunc);
}
let funcOff = L.top - (nargs + 1); /* function to be called */
diff --git a/src/lbaselib.js b/src/lbaselib.js
index 4212525..13644ef 100644
--- a/src/lbaselib.js
+++ b/src/lbaselib.js
@@ -382,7 +382,6 @@ const luaB_xpcall = function(L) {
return finishpcall(L, status, 2);
};
-// TODO: does it overwrite the upvalue of the previous closure ?
const load_aux = function(L, status, envidx) {
if (status === LUA_OK) {
if (envidx !== 0) { /* 'env' parameter? */
diff --git a/src/ldo.js b/src/ldo.js
index b138e47..5f849ca 100644
--- a/src/ldo.js
+++ b/src/ldo.js
@@ -393,7 +393,7 @@ const luaD_throw = function(L, errcode) {
const luaD_rawrunprotected = function(L, f, ud) {
let oldnCcalls = L.nCcalls;
- let lj = { // TODO: necessary when using try/catch ? (ldo.c:47-52)
+ let lj = {
status: LUA_OK,
previous: L.errorJmp /* chain new error handler */
};
diff --git a/src/llex.js b/src/llex.js
index 360e3d7..d9af318 100644
--- a/src/llex.js
+++ b/src/llex.js
@@ -653,7 +653,7 @@ const luaX_next = function(ls) {
ls.t.token = ls.lookahead.token; /* use this one */
ls.t.seminfo.i = ls.lookahead.seminfo.i;
ls.t.seminfo.r = ls.lookahead.seminfo.r;
- ls.t.seminfo.ts = ls.lookahead.seminfo.ts; // TODO ?
+ ls.t.seminfo.ts = ls.lookahead.seminfo.ts;
ls.lookahead.token = TK_EOS; /* and discharge it */
} else
ls.t.token = llex(ls, ls.t.seminfo); /* read next token */
diff --git a/src/loadlib.js b/src/loadlib.js
index 147b942..aa7a372 100644
--- a/src/loadlib.js
+++ b/src/loadlib.js
@@ -207,7 +207,6 @@ if (typeof process !== "undefined") { // Only with Node
return true;
};
} else {
- /* TODO: use async/await ? */
readable = function(path) {
path = to_uristring(path);
let xhr = new XMLHttpRequest();
diff --git a/src/loslib.js b/src/loslib.js
index 9a8a327..53a4228 100644
--- a/src/loslib.js
+++ b/src/loslib.js
@@ -244,7 +244,6 @@ if (typeof process === "undefined") {
return 1;
};
- // TODO: on POSIX system, should create the file
const lua_tmpname = function() {
return tmp.tmpNameSync();
};