diff options
Diffstat (limited to 'script/vm/global.lua')
-rw-r--r-- | script/vm/global.lua | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/script/vm/global.lua b/script/vm/global.lua index 50febd2c..b94e2768 100644 --- a/script/vm/global.lua +++ b/script/vm/global.lua @@ -162,6 +162,9 @@ local compilerGlobalSwitch = util.switch() : call(function (source) local uri = guide.getUri(source) local name = guide.getKeyName(source) + if not name then + return + end local global = vm.declareGlobal('variable', name, uri) global:addSet(uri, source) source._globalNode = global @@ -170,6 +173,9 @@ local compilerGlobalSwitch = util.switch() : call(function (source) local uri = guide.getUri(source) local name = guide.getKeyName(source) + if not name then + return + end local global = vm.declareGlobal('variable', name, uri) global:addGet(uri, source) source._globalNode = global @@ -272,6 +278,9 @@ local compilerGlobalSwitch = util.switch() : call(function (source) local uri = guide.getUri(source) local name = guide.getKeyName(source) + if not name then + return + end local class = vm.declareGlobal('type', name, uri) class:addSet(uri, source) source._globalNode = class @@ -294,6 +303,9 @@ local compilerGlobalSwitch = util.switch() : call(function (source) local uri = guide.getUri(source) local name = guide.getKeyName(source) + if not name then + return + end local alias = vm.declareGlobal('type', name, uri) alias:addSet(uri, source) source._globalNode = alias |