Module:User:Surjection/invoker/default
Appearance
- This module sandbox lacks a documentation subpage. Please create it.
- Useful links: root page • root page’s subpages • links • transclusions • testcases • sandbox
local getParent = function (frame) return frame._parent end
local function makeFakeFrame(tempargs, args)
local frame = { }
frame._parent = { ["args"] = args }
frame.getParent = getParent
frame.args = tempargs
return frame
end
-- tries to construct a fake frame and call a template entry point with it
return function (entry, tempargs)
return function (args)
return entry(makeFakeFrame(tempargs or nil, args))
end
end