diff options
author | Hans Hagen <pragma@wxs.nl> | 2019-11-12 19:54:50 +0100 |
---|---|---|
committer | Context Git Mirror Bot <phg@phi-gamma.net> | 2019-11-12 19:54:50 +0100 |
commit | 0c75a2acf592eb4360685375904440f5e6b8125a (patch) | |
tree | 0a23a35bf947d13b3975bacdc27ad1d7edc9454c /tex/context/base/mkiv/util-sta.lua | |
parent | 5c195236a1a69b23762df71a791e6b4e2c671892 (diff) | |
download | context-0c75a2acf592eb4360685375904440f5e6b8125a.tar.gz |
2019-11-12 18:53:00
Diffstat (limited to 'tex/context/base/mkiv/util-sta.lua')
-rw-r--r-- | tex/context/base/mkiv/util-sta.lua | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/tex/context/base/mkiv/util-sta.lua b/tex/context/base/mkiv/util-sta.lua index 7819395f6..9ca1c67e9 100644 --- a/tex/context/base/mkiv/util-sta.lua +++ b/tex/context/base/mkiv/util-sta.lua @@ -81,6 +81,8 @@ end function stacker.new(name) + -- to be sped up, mmaybe foo:bar syntax here but then quite some access + local report = logs.reporter("stacker",name or nil) local s @@ -93,6 +95,7 @@ function stacker.new(name) local hashing = true local function push(...) + -- todo check if more than 1 argument for i=1,select("#",...) do insert(stack,(select(i,...))) -- watch the () end @@ -153,8 +156,12 @@ function stacker.new(name) local function resolve_step(ti) -- keep track of changes outside function ! -- todo: optimize for n=1 etc + if not top then + -- report("messed op stacker %a",name) + return + end local result = nil - local noftop = top and #top or 0 + local noftop = #top if ti > 0 then local current = list[ti] if current then |