From 833bfb207b3f924eaa81feb496cf74e6223d0041 Mon Sep 17 00:00:00 2001 From: ruki Date: Mon, 11 Apr 2016 14:08:47 +0800 Subject: add new tool module --- xmake/core/project/task.lua | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'xmake/core/project/task.lua') diff --git a/xmake/core/project/task.lua b/xmake/core/project/task.lua index 22cee9714..98cf00454 100644 --- a/xmake/core/project/task.lua +++ b/xmake/core/project/task.lua @@ -175,7 +175,7 @@ function task._interpreter() , "before") -- set filter - interp:filter_set(filter.init(function (variable) + interp:filter_set(filter.new(function (variable) -- check assert(variable) @@ -188,6 +188,7 @@ function task._interpreter() local maps = { host = xmake._HOST + , nuldev = xmake._NULDEV , tmpdir = os.tmpdir() , curdir = os.curdir() , globaldir = global.directory() @@ -239,7 +240,7 @@ function task._bind(tasks) if type(opt) == "function" then -- make sandbox instance with the given script - local instance, errors = sandbox.new(opt, interp) + local instance, errors = sandbox.new(opt, interp:filter(), interp:rootdir()) if not instance then return false, errors end @@ -271,7 +272,7 @@ function task._bind(tasks) if type(description) == "function" then -- make sandbox instance with the given script - local instance, errors = sandbox.new(description, interp) + local instance, errors = sandbox.new(description, interp:filter(), interp:rootdir()) if not instance then return false, errors end -- cgit v1.3.1