aboutsummaryrefslogtreecommitdiff
path: root/nomsu_environment.moon
diff options
context:
space:
mode:
authorBruce Hill <bruce@bruce-hill.com>2018-12-31 00:27:49 -0800
committerBruce Hill <bruce@bruce-hill.com>2018-12-31 00:28:08 -0800
commitdff2c1c915d63745cdfc594ae810cc92bd425cef (patch)
tree8bf78cfce772584eaf6deebac4f305f11dc1b6fb /nomsu_environment.moon
parentfaaf5311c8d94b3cb0ccfbecf7b034e529c6e7b7 (diff)
Fixed bug where cached files would incorrectly appear to not have been
found.
Diffstat (limited to 'nomsu_environment.moon')
-rw-r--r--nomsu_environment.moon3
1 files changed, 2 insertions, 1 deletions
diff --git a/nomsu_environment.moon b/nomsu_environment.moon
index 6986b77..5d7a02c 100644
--- a/nomsu_environment.moon
+++ b/nomsu_environment.moon
@@ -182,6 +182,7 @@ nomsu_environment = Importer{
-- Need to check here to prevent re-running files
if environment.FILE_CACHE[filename]
import_to_1_from(environment, environment.FILE_CACHE[filename], prefix)
+ did_anything = true
continue
-- TODO: don't automatically use precompiled version?
code = if optimization != 0 and Files.read(lua_filename)
@@ -195,7 +196,7 @@ nomsu_environment = Importer{
did_anything = true
break
unless did_anything
- error("File not found: #{path}", 0)
+ error("File not found: #{path}\n(searched in #{package.nomsupath})", 0)
import_to_1_from(environment, mod, prefix)
environment.FILE_CACHE[path] = mod
_currently_running_files\remove!