Add tasks for all the new languages
This commit is contained in:
parent
9dc3c2bb62
commit
bba7bfd280
13208 changed files with 134745 additions and 0 deletions
34
Task/Function-composition/Lingo/function-composition-2.lingo
Normal file
34
Task/Function-composition/Lingo/function-composition-2.lingo
Normal file
|
|
@ -0,0 +1,34 @@
|
|||
-- parent script "Composer"
|
||||
|
||||
property _f
|
||||
property _g
|
||||
|
||||
----------------------------------------
|
||||
-- @constructor
|
||||
-- @param {symbol|instance} f
|
||||
-- @param {symbol|instance} g
|
||||
----------------------------------------
|
||||
on new (me, f, g)
|
||||
me._f = f
|
||||
me._g = g
|
||||
return me
|
||||
end
|
||||
|
||||
on call (me)
|
||||
if ilk(me._g)=#instance then
|
||||
cmd = "_movie.call(#call,me._g,VOID"
|
||||
else
|
||||
cmd = "_movie.call(me._g,_movie"
|
||||
end if
|
||||
a = [] -- local args list
|
||||
repeat with i = 1 to the paramCount-2
|
||||
a[i] = param(i+2)
|
||||
put ",a["&i&"]" after cmd
|
||||
end repeat
|
||||
put ")" after cmd
|
||||
if ilk(me._f)=#instance then
|
||||
return _movie.call(#call, me._f, VOID, value(cmd))
|
||||
else
|
||||
return _movie.call(me._f, _movie, value(cmd))
|
||||
end if
|
||||
end
|
||||
Loading…
Add table
Add a link
Reference in a new issue