From b6c99c56a1f49a9230b65200a5a016173038857c Mon Sep 17 00:00:00 2001 From: Bruce Hill Date: Tue, 24 Jul 2018 15:08:44 -0700 Subject: Updated package.nomsupath behavior to first search the installed locations, *then* search the current directory. This makes the system `nomsu` run properly, even if the local directory has a broken file that has the same name as a nomsu file. --- nomsu_compiler.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'nomsu_compiler.lua') diff --git a/nomsu_compiler.lua b/nomsu_compiler.lua index 42b1a1d..56bd1e8 100644 --- a/nomsu_compiler.lua +++ b/nomsu_compiler.lua @@ -158,7 +158,7 @@ local NomsuCompiler = setmetatable({ }, { end }) do - NomsuCompiler.NOMSU_COMPILER_VERSION = 4 + NomsuCompiler.NOMSU_COMPILER_VERSION = 5 NomsuCompiler.NOMSU_SYNTAX_VERSION = Parser.version NomsuCompiler._ENV = NomsuCompiler NomsuCompiler.nomsu = NomsuCompiler @@ -454,7 +454,7 @@ do if not (ran_lua) then local file = Files.read(filename) if not file then - error("File does not exist: " .. tostring(filename), 0) + error("Tried to run file that does not exist: " .. tostring(filename)) end ret = self:run(file, Source(filename, 1, #file)) end -- cgit v1.2.3