summaryrefslogtreecommitdiff
path: root/tex/context/base/mkiv/strc-doc.lua
diff options
context:
space:
mode:
authorHans Hagen <pragma@wxs.nl>2017-02-17 10:31:56 +0100
committerContext Git Mirror Bot <phg42.2a@gmail.com>2017-02-17 10:31:56 +0100
commitb14f992ef5f4e868c9959b174278c86516d60dbc (patch)
tree28587bb46c025ea7b0d27ba93f09c93dcf53c73a /tex/context/base/mkiv/strc-doc.lua
parent95a1799032dc61dbca4a11e495be34b4397c8fec (diff)
downloadcontext-b14f992ef5f4e868c9959b174278c86516d60dbc.tar.gz
2017-02-17 10:23:00
Diffstat (limited to 'tex/context/base/mkiv/strc-doc.lua')
-rw-r--r--tex/context/base/mkiv/strc-doc.lua15
1 files changed, 8 insertions, 7 deletions
diff --git a/tex/context/base/mkiv/strc-doc.lua b/tex/context/base/mkiv/strc-doc.lua
index 105e5ad8d..57fff5a21 100644
--- a/tex/context/base/mkiv/strc-doc.lua
+++ b/tex/context/base/mkiv/strc-doc.lua
@@ -16,7 +16,7 @@ if not modules then modules = { } end modules ['strc-doc'] = {
-- in lists however zero's are ignored, so there numbersegments=2:4 gives result
local next, type, tonumber, select = next, type, tonumber, select
-local format, gsub, find, gmatch, match = string.format, string.gsub, string.find, string.gmatch, string.match
+local find, match = string.find, string.match
local concat, fastcopy, insert, remove = table.concat, table.fastcopy, table.insert, table.remove
local max, min = math.max, math.min
local allocate, mark, accesstable = utilities.storage.allocate, utilities.storage.mark, utilities.tables.accesstable
@@ -411,16 +411,17 @@ function sections.setentry(given)
v[2](k)
end
end
- local n = { }
- for i=1,newdepth do
- n[i] = numbers[i]
- end
- numberdata.numbers = n
+-- local n = { }
+-- for i=1,newdepth do
+-- n[i] = numbers[i]
+-- end
+-- numberdata.numbers = n
+ numberdata.numbers = { unpack(numbers,1,newdepth) }
if not numberdata.block then
numberdata.block = getcurrentblock() -- also in references
end
if #ownnumbers > 0 then
- numberdata.ownnumbers = fastcopy(ownnumbers)
+ numberdata.ownnumbers = fastcopy(ownnumbers) -- { unpack(ownnumbers) }
end
if trace_detail then
report_structure("name %a, numbers % a, own numbers % a",givenname,numberdata.numbers,numberdata.ownnumbers)