function luaY.whilestat(t,R,k)local u=R.fs local n={}luaX:next(R)local L=luaK:getlabel(u)local W=t:cond(R)t:enterblock(u,n,true)t:checknext(R,"\084\075\095\068\079")t:block(R)luaK:patchlist(u,luaK:jump(u),L)t:check_match(R,"\084\075\095\069\078\068","\084\075\095\087\072\073\076\069",k)t:leaveblock(u)luaK:patchtohere(u,W)end

function luaY:whilestat(ls, line)
  -- whilestat -> WHILE cond DO block END
  local fs = ls.fs
  local bl = {}  -- BlockCnt
  luaX:next(ls)  -- skip WHILE
  local whileinit = luaK:getlabel(fs)
  local condexit = self:cond(ls)
  self:enterblock(fs, bl, true)
  self:checknext(ls, "TK_DO")
  self:block(ls)
  luaK:patchlist(fs, luaK:jump(fs), whileinit)
  self:check_match(ls, "TK_END", "TK_WHILE", line)
  self:leaveblock(fs)
  luaK:patchtohere(fs, condexit)  -- false conditions finish the loop
end
