oops, rebuild

This commit is contained in:
leaf corcoran 2013-01-12 15:18:44 -08:00
parent 0cf96b97f6
commit 1bff5ea9be

View File

@ -66,17 +66,13 @@ apply_to_last = function(stms, fn)
local _accum_0 = { } local _accum_0 = { }
local _len_0 = 1 local _len_0 = 1
for i, stm in ipairs(stms) do for i, stm in ipairs(stms) do
local _value_0
if i == last_exp_id then if i == last_exp_id then
_value_0 = fn(stm) _accum_0[_len_0] = fn(stm)
else else
_value_0 = stm _accum_0[_len_0] = stm
end end
if _value_0 ~= nil then
_accum_0[_len_0] = _value_0
_len_0 = _len_0 + 1 _len_0 = _len_0 + 1
end end
end
return _accum_0 return _accum_0
end)() end)()
end end
@ -463,20 +459,16 @@ local Statement = Transformer({
local _list_0 = names local _list_0 = names
for _index_0 = 1, #_list_0 do for _index_0 = 1, #_list_0 do
local name = _list_0[_index_0] local name = _list_0[_index_0]
local _value_0
if type(name) == "table" then if type(name) == "table" then
_value_0 = name _accum_0[_len_0] = name
else else
_value_0 = { _accum_0[_len_0] = {
"dot", "dot",
name name
} }
end end
if _value_0 ~= nil then
_accum_0[_len_0] = _value_0
_len_0 = _len_0 + 1 _len_0 = _len_0 + 1
end end
end
return _accum_0 return _accum_0
end)() end)()
local real_names = (function() local real_names = (function()
@ -485,12 +477,9 @@ local Statement = Transformer({
local _list_0 = names local _list_0 = names
for _index_0 = 1, #_list_0 do for _index_0 = 1, #_list_0 do
local name = _list_0[_index_0] local name = _list_0[_index_0]
local _value_0 = type(name) == "table" and name[2] or name _accum_0[_len_0] = type(name) == "table" and name[2] or name
if _value_0 ~= nil then
_accum_0[_len_0] = _value_0
_len_0 = _len_0 + 1 _len_0 = _len_0 + 1
end end
end
return _accum_0 return _accum_0
end)() end)()
if type(source) == "string" then if type(source) == "string" then
@ -711,22 +700,18 @@ local Statement = Transformer({
local _accum_0 = { } local _accum_0 = { }
local _len_0 = 1 local _len_0 = 1
for i, name in ipairs(node.names) do for i, name in ipairs(node.names) do
local _value_0
if ntype(name) == "table" then if ntype(name) == "table" then
do do
local _with_0 = NameProxy("des") local _with_0 = NameProxy("des")
local proxy = _with_0 local proxy = _with_0
insert(destructures, destructure.build_assign(name, proxy)) insert(destructures, destructure.build_assign(name, proxy))
_value_0 = _with_0 _accum_0[_len_0] = _with_0
end end
else else
_value_0 = name _accum_0[_len_0] = name
end end
if _value_0 ~= nil then
_accum_0[_len_0] = _value_0
_len_0 = _len_0 + 1 _len_0 = _len_0 + 1
end end
end
return _accum_0 return _accum_0
end)() end)()
if next(destructures) then if next(destructures) then
@ -906,10 +891,8 @@ local Statement = Transformer({
else else
_value_0 = tuple _value_0 = tuple
end end
if _value_0 ~= nil then
_accum_0[_len_0] = _value_0 _accum_0[_len_0] = _value_0
_len_0 = _len_0 + 1 _len_0 = _len_0 + 1
end
_continue_0 = true _continue_0 = true
until true until true
if not _continue_0 then if not _continue_0 then