This commit is contained in:
leaf corcoran 2015-09-26 20:06:19 -07:00
parent 326e4208cb
commit 9dbc1d5062
3 changed files with 4 additions and 4 deletions

View File

@ -66,9 +66,7 @@ end
moon_loader = function(name)
local name_path = name:gsub("%.", dirsep)
local file, file_path
local _list_0 = split(package.moonpath, ";")
for _index_0 = 1, #_list_0 do
local path = _list_0[_index_0]
for path in package.moonpath:gmatch("[^;]+") do
file_path = path:gsub("?", name_path)
file = io.open(file_path)
if file then

View File

@ -38,7 +38,7 @@ moon_loader = (name) ->
name_path = name\gsub "%.", dirsep
local file, file_path
for path in *split package.moonpath, ";"
for path in package.moonpath\gmatch "[^;]+"
file_path = path\gsub "?", name_path
file = io.open file_path
break if file

View File

@ -406,6 +406,8 @@ class Block
nil
-- takes the existing set of lines and replaces them with the result of
-- calling fn on them
splice: (fn) =>
lines = {"lines", @_lines}
@_lines = Lines!