From f42baa3087685417a280abf8bb4283afb9d5f3f9 Mon Sep 17 00:00:00 2001 From: Benoit Giannangeli Date: Thu, 11 May 2017 11:17:11 +0200 Subject: Freeze luaO_nilobject to catch any accidental overwrite To remove along with asserts calls for any real use --- src/lobject.js | 1 + 1 file changed, 1 insertion(+) (limited to 'src') diff --git a/src/lobject.js b/src/lobject.js index fe23d24..f926e85 100644 --- a/src/lobject.js +++ b/src/lobject.js @@ -182,6 +182,7 @@ class TValue { } const luaO_nilobject = new TValue(CT.LUA_TNIL, null); +Object.freeze(luaO_nilobject); module.exports.luaO_nilobject = luaO_nilobject; class LClosure { -- cgit v1.2.3-70-g09d2