summaryrefslogtreecommitdiff
path: root/tex
diff options
context:
space:
mode:
authorHans Hagen <pragma@wxs.nl>2018-08-19 13:10:04 +0200
committerContext Git Mirror Bot <phg@phi-gamma.net>2018-08-19 13:10:04 +0200
commit7539371c37c02bc2bc6c5d7ebffa2ffc6fec36c3 (patch)
tree8a2e1e9bfba18c3ee1897eda50f76f4726bdd108 /tex
parent0fcb576f359edfdd50c2b13615a03b966a9073df (diff)
downloadcontext-7539371c37c02bc2bc6c5d7ebffa2ffc6fec36c3.tar.gz
2018-08-19 13:00:00
Diffstat (limited to 'tex')
-rw-r--r--tex/context/base/mkii/cont-new.mkii2
-rw-r--r--tex/context/base/mkii/context.mkii2
-rw-r--r--tex/context/base/mkiv/cldf-bas.lua56
-rw-r--r--tex/context/base/mkiv/cldf-ini.lua18
-rw-r--r--tex/context/base/mkiv/cont-new.mkiv2
-rw-r--r--tex/context/base/mkiv/context.mkiv2
-rw-r--r--tex/context/base/mkiv/font-oup.lua91
-rw-r--r--tex/context/base/mkiv/grph-rul.lua15
-rw-r--r--tex/context/base/mkiv/node-met.lua1
-rw-r--r--tex/context/base/mkiv/node-nut.lua12
-rw-r--r--tex/context/base/mkiv/node-res.lua4
-rw-r--r--tex/context/base/mkiv/node-rul.lua13
-rw-r--r--tex/context/base/mkiv/node-tra.lua3
-rw-r--r--tex/context/base/mkiv/status-files.pdfbin26296 -> 26289 bytes
-rw-r--r--tex/context/base/mkiv/status-lua.pdfbin267098 -> 268041 bytes
-rw-r--r--tex/context/base/mkiv/strc-lst.lua1
-rw-r--r--tex/context/base/mkiv/strc-ref.lua1
-rw-r--r--tex/context/base/mkiv/strc-reg.lua1
-rw-r--r--tex/context/base/mkiv/typo-mar.lua3
-rw-r--r--tex/context/interface/mkiv/i-context.pdfbin853701 -> 853815 bytes
-rw-r--r--tex/context/interface/mkiv/i-readme.pdfbin61219 -> 61224 bytes
-rw-r--r--tex/context/modules/mkiv/s-youless.mkiv8
-rw-r--r--tex/generic/context/luatex/luatex-fonts-merged.lua93
23 files changed, 201 insertions, 127 deletions
diff --git a/tex/context/base/mkii/cont-new.mkii b/tex/context/base/mkii/cont-new.mkii
index 40286f161..3ef841bd7 100644
--- a/tex/context/base/mkii/cont-new.mkii
+++ b/tex/context/base/mkii/cont-new.mkii
@@ -11,7 +11,7 @@
%C therefore copyrighted by \PRAGMA. See mreadme.pdf for
%C details.
-\newcontextversion{2018.08.16 10:17}
+\newcontextversion{2018.08.19 12:52}
%D This file is loaded at runtime, thereby providing an
%D excellent place for hacks, patches, extensions and new
diff --git a/tex/context/base/mkii/context.mkii b/tex/context/base/mkii/context.mkii
index 290233d37..c541e2a5a 100644
--- a/tex/context/base/mkii/context.mkii
+++ b/tex/context/base/mkii/context.mkii
@@ -20,7 +20,7 @@
%D your styles an modules.
\edef\contextformat {\jobname}
-\edef\contextversion{2018.08.16 10:17}
+\edef\contextversion{2018.08.19 12:52}
%D For those who want to use this:
diff --git a/tex/context/base/mkiv/cldf-bas.lua b/tex/context/base/mkiv/cldf-bas.lua
index af698ac97..4ad0c5a48 100644
--- a/tex/context/base/mkiv/cldf-bas.lua
+++ b/tex/context/base/mkiv/cldf-bas.lua
@@ -22,27 +22,30 @@ if not modules then modules = { } end modules ['cldf-bas'] = {
-- flush(ctxcatcodes,"}")
-- end
-local tonumber = tonumber
-local type = type
-local format = string.format
-local utfchar = utf.char
-local concat = table.concat
+local tonumber = tonumber
+local type = type
+local format = string.format
+local utfchar = utf.char
+local concat = table.concat
-local context = context
-local ctxcore = context.core
-local variables = interfaces.variables
-local sprint = context.sprint
+local context = context
+local ctxcore = context.core
-local nodepool = nodes.pool
-local new_rule = nodepool.rule
-local new_glyph = nodepool.glyph
-local new_latelua = nodepool.latelua
+local variables = interfaces.variables
-local current_attr = nodes.current_attr
+local ctx_flushnode = context.nuts.flush
-local current_font = font.current
-local texgetcount = tex.getcount
-local texsetcount = tex.setcount
+local nuts = nodes.nuts
+local tonode = nuts.tonode
+local nodepool = nuts.pool
+local new_rule = nodepool.rule
+local new_glyph = nodepool.glyph
+local new_latelua = nodepool.latelua
+
+local setattrlist = nuts.setattrlist
+
+local texgetcount = tex.getcount
+local texsetcount = tex.setcount
-- a set of basic fast ones
@@ -80,19 +83,20 @@ function context.rule(w,h,d,dir)
else
rule = new_rule(w,h,d,dir)
end
- rule.attr = current_attr()
- context(rule)
+ setattrlist(rule,true)
+ context(tonode(rule))
+ -- ctx_flushnode(tonode(rule))
end
function context.glyph(id,k)
if id then
if not k then
- id, k = current_font(), id
+ id, k = true, id
end
local glyph = new_glyph(id,k)
- glyph.attr = current_attr()
- context(glyph)
- -- context.node(glyph)
+ setattrlist(glyph,true)
+ context(tonode(glyph))
+ -- ctx_flushnode(tonode(glyph))
end
end
@@ -178,10 +182,10 @@ context.registers = {
do
- local ctx_flushnode = context.nodes.flush
-
function context.latelua(f)
- ctx_flushnode(new_latelua(f))
+ local latelua = new_latelua(f)
+ setattrlist(latelua,true)
+ ctx_flushnode(latelua)
end
end
diff --git a/tex/context/base/mkiv/cldf-ini.lua b/tex/context/base/mkiv/cldf-ini.lua
index a7975eec4..d92003c51 100644
--- a/tex/context/base/mkiv/cldf-ini.lua
+++ b/tex/context/base/mkiv/cldf-ini.lua
@@ -90,6 +90,7 @@ local isnode = node.is_node
local writenode = node.write
local copynodelist = node.copy_list
local tonut = node.direct.todirect
+local tonode = node.direct.tonode
local istoken = token.is_token
local newtoken = token.new
@@ -1111,6 +1112,23 @@ context.nodes = { -- todo
end,
}
+context.nuts = { -- todo
+ store = function(n)
+ return storenode(tonut(n))
+ end,
+ flush = function(n)
+ if nodeflushmode then
+ if n <= maxflushnodeindex then
+ flush(tonode(n))
+ else
+ flush(currentcatcodes,s_cldl_option_s,storenode(tonode(n))," ")
+ end
+ else
+ flush(currentcatcodes,s_cldl_option_s,storenode(tonode(n))," ")
+ end
+ end,
+}
+
local defaultcaller = caller
setmetatableindex(context,indexer)
diff --git a/tex/context/base/mkiv/cont-new.mkiv b/tex/context/base/mkiv/cont-new.mkiv
index fdf68f8d7..d6e000f00 100644
--- a/tex/context/base/mkiv/cont-new.mkiv
+++ b/tex/context/base/mkiv/cont-new.mkiv
@@ -11,7 +11,7 @@
%C therefore copyrighted by \PRAGMA. See mreadme.pdf for
%C details.
-\newcontextversion{2018.08.16 10:17}
+\newcontextversion{2018.08.19 12:52}
%D This file is loaded at runtime, thereby providing an excellent place for
%D hacks, patches, extensions and new features.
diff --git a/tex/context/base/mkiv/context.mkiv b/tex/context/base/mkiv/context.mkiv
index f04ada119..ba861fab5 100644
--- a/tex/context/base/mkiv/context.mkiv
+++ b/tex/context/base/mkiv/context.mkiv
@@ -42,7 +42,7 @@
%D has to match \type {YYYY.MM.DD HH:MM} format.
\edef\contextformat {\jobname}
-\edef\contextversion{2018.08.16 10:17}
+\edef\contextversion{2018.08.19 12:52}
\edef\contextkind {beta}
%D For those who want to use this:
diff --git a/tex/context/base/mkiv/font-oup.lua b/tex/context/base/mkiv/font-oup.lua
index 7ba8af8b1..562d7561d 100644
--- a/tex/context/base/mkiv/font-oup.lua
+++ b/tex/context/base/mkiv/font-oup.lua
@@ -814,9 +814,9 @@ function readers.getcomponents(fontdata) -- handy for resolving ligatures when n
end
for i=1,#steps do
-- we actually had/have this in base mode
- local coverage = steps[i].coverage
- if coverage then
- for k, v in next, coverage do
+ local c = steps[i].coverage
+ if c then
+ for k, v in next, c do
traverse(k,k,v)
end
end
@@ -2134,9 +2134,12 @@ local function mergesteps_1(lookup,strict)
report("merging %a steps of %a lookup %a",nofsteps,lookup.type,lookup.name)
local target = first.coverage
for i=2,nofsteps do
- for k, v in next, steps[i].coverage do
- if not target[k] then
- target[k] = v
+ local c = steps[i].coverage
+ if c then
+ for k, v in next, c do
+ if not target[k] then
+ target[k] = v
+ end
end
end
end
@@ -2165,16 +2168,19 @@ local function mergesteps_2(lookup) -- pairs
report("merging %a steps of %a lookup %a",nofsteps,lookup.type,lookup.name)
local target = first.coverage
for i=2,nofsteps do
- for k, v in next, steps[i].coverage do
- local tk = target[k]
- if tk then
- for kk, vv in next, v do
- if tk[kk] == nil then
- tk[kk] = vv
+ local c = steps[i].coverage
+ if c then
+ for k, v in next, c do
+ local tk = target[k]
+ if tk then
+ for kk, vv in next, v do
+ if tk[kk] == nil then
+ tk[kk] = vv
+ end
end
+ else
+ target[k] = v
end
- else
- target[k] = v
end
end
end
@@ -2194,13 +2200,16 @@ local function mergesteps_3(lookup,strict) -- marks
-- check first
local coverage = { }
for i=1,nofsteps do
- for k, v in next, steps[i].coverage do
- local tk = coverage[k] -- { class, { x, y } }
- if tk then
- report("quitting merge due to multiple checks")
- return nofsteps
- else
- coverage[k] = v
+ local c = steps[i].coverage
+ if c then
+ for k, v in next, c do
+ local tk = coverage[k] -- { class, { x, y } }
+ if tk then
+ report("quitting merge due to multiple checks")
+ return nofsteps
+ else
+ coverage[k] = v
+ end
end
end
end
@@ -2249,12 +2258,15 @@ local function mergesteps_4(lookup) -- ligatures
report("merging %a steps of %a lookup %a",nofsteps,lookup.type,lookup.name)
local target = first.coverage
for i=2,nofsteps do
- for k, v in next, steps[i].coverage do
- local tk = target[k]
- if tk then
- nested(v,tk)
- else
- target[k] = v
+ local c = steps[i].coverage
+ if c then
+ for k, v in next, c do
+ local tk = target[k]
+ if tk then
+ nested(v,tk)
+ else
+ target[k] = v
+ end
end
end
end
@@ -2279,18 +2291,21 @@ local function mergesteps_5(lookup) -- cursive
break
end
for i=2,nofsteps do
- for k, v in next, steps[i].coverage do
- local tk = target[k]
- if tk then
- if not tk[2] then
- tk[2] = v[2]
- end
- if not tk[3] then
- tk[3] = v[3]
+ local c = steps[i].coverage
+ if c then
+ for k, v in next, c do
+ local tk = target[k]
+ if tk then
+ if not tk[2] then
+ tk[2] = v[2]
+ end
+ if not tk[3] then
+ tk[3] = v[3]
+ end
+ else
+ target[k] = v
+ v[1] = hash
end
- else
- target[k] = v
- v[1] = hash
end
end
end
diff --git a/tex/context/base/mkiv/grph-rul.lua b/tex/context/base/mkiv/grph-rul.lua
index 71f1f868c..809854986 100644
--- a/tex/context/base/mkiv/grph-rul.lua
+++ b/tex/context/base/mkiv/grph-rul.lua
@@ -12,13 +12,12 @@ local attributes = attributes
local nodes = nodes
local context = context
+local nuts = nodes.nuts
local ruleactions = nodes.rules.ruleactions
-local userrule = nodes.rules.userrule
+local userrule = nuts.rules.userrule
local bpfactor = number.dimenfactors.bp
-local current_attr = nodes.current_attr
-local setfield = nodes.setfield
-
+local setattrlist = nuts.setattrlist
local getattribute = tex.getattribute
local a_color = attributes.private('color')
@@ -232,7 +231,7 @@ interfaces.implement {
local ma = getattribute(a_colormodel) or 1
local ca = getattribute(a_color)
local ta = getattribute(a_transparency)
- setfield(rule,"attr",current_attr())
+ setattrlist(rule,true)
if t.type == "mp" then
t.ma = ma
t.ca = ca
@@ -242,7 +241,7 @@ interfaces.implement {
rule[a_color] = ca
rule[a_transparency] = ta
end
- context(rule)
+ context(tonode(rule))
end
}
@@ -269,8 +268,8 @@ interfaces.implement {
type = "mp",
name = t.name,
}
- setfield(rule,"attr",current_attr())
- context(rule)
+ setattrlist(rule,true)
+ context(tonode(rule))
end
}
diff --git a/tex/context/base/mkiv/node-met.lua b/tex/context/base/mkiv/node-met.lua
index 3ec03458d..3116cf2fb 100644
--- a/tex/context/base/mkiv/node-met.lua
+++ b/tex/context/base/mkiv/node-met.lua
@@ -725,4 +725,3 @@ if not nodes.unprotect_glyph then
end
end
-
diff --git a/tex/context/base/mkiv/node-nut.lua b/tex/context/base/mkiv/node-nut.lua
index 55d292af7..bccf9e069 100644
--- a/tex/context/base/mkiv/node-nut.lua
+++ b/tex/context/base/mkiv/node-nut.lua
@@ -1024,3 +1024,15 @@ function nuts.copy_properties(source,target,what)
return newprops -- for checking
end
+if LUATEXFUNCTIONALITY < 6894 then
+
+ local sal = nuts.setattrlist
+ local cal = nuts.current_attr
+
+ function nuts.setattrlist(n,a)
+ return sal(n,a == true and cal() or a)
+ end
+
+ nuts.setattributelist = nuts.setattrlist
+
+end
diff --git a/tex/context/base/mkiv/node-res.lua b/tex/context/base/mkiv/node-res.lua
index b591cafdf..3eedc2348 100644
--- a/tex/context/base/mkiv/node-res.lua
+++ b/tex/context/base/mkiv/node-res.lua
@@ -32,6 +32,8 @@ local usercodes = nodes.usercodes
local glyph_code = nodecodes.glyph
+local currentfont = font.current
+
local allocate = utilities.storage.allocate
local texgetcount = tex.getcount
@@ -213,7 +215,7 @@ local vlist = register_nut(new_nut(nodecodes.vlist))
function nutpool.glyph(fnt,chr)
local n = copy_nut(glyph)
if fnt then
- setfont(n,fnt,chr)
+ setfont(n,fnt == true and currentfont() or fnt,chr)
elseif chr then
setchar(n,chr)
end
diff --git a/tex/context/base/mkiv/node-rul.lua b/tex/context/base/mkiv/node-rul.lua
index bb63e6668..3b5a036ea 100644
--- a/tex/context/base/mkiv/node-rul.lua
+++ b/tex/context/base/mkiv/node-rul.lua
@@ -58,7 +58,6 @@ local find_tail = nuts.tail
local setglue = nuts.setglue
local list_dimensions = nuts.rangedimensions
local hpack_nodes = nuts.hpack
-local current_attr = nuts.current_attr
local copy_list = nuts.copy_list
local nexthlist = nuts.traversers.hlist
@@ -145,7 +144,7 @@ local function usernutrule(t,noattributes)
if noattributes == false or noattributes == nil then
-- avoid fuzzy ones
else
- setattrlist(r,current_attr())
+ setattrlist(r,true)
end
properties[r] = t
return r
@@ -157,9 +156,11 @@ local function userrule(t,noattributes)
return tonode(usernutrule(t,noattributes))
end
-rules.userrule = userrule
-local ruleactions = { }
-rules.ruleactions = ruleactions
+rules.userrule = userrule
+local ruleactions = { }
+
+rules .ruleactions = ruleactions
+nutrules.ruleactions = ruleactions -- convenient
local function mathradical(n,h,v)
----- size = getfield(n,"index")
@@ -893,7 +894,7 @@ interfaces.implement {
t.height,
t.depth
)
- setattrlist(n,current_attr())
+ setattrlist(n,true)
if LUATEXFUNCTIONALITY >= 6710 then
if l then
setfield(n,"left",l)
diff --git a/tex/context/base/mkiv/node-tra.lua b/tex/context/base/mkiv/node-tra.lua
index 7f359d7fd..6d6f1a554 100644
--- a/tex/context/base/mkiv/node-tra.lua
+++ b/tex/context/base/mkiv/node-tra.lua
@@ -656,6 +656,9 @@ end
tracers.setproperties = setproperties
+-- setting attrlist entries instead of attr for successive entries doesn't
+-- speed up much (this function is only used in tracers anyway)
+
function tracers.setlist(n,c,s)
local nn = tonut(n)
local mc = m_color[c]
diff --git a/tex/context/base/mkiv/status-files.pdf b/tex/context/base/mkiv/status-files.pdf
index 5b0fd601e..2223d9b0b 100644
--- a/tex/context/base/mkiv/status-files.pdf
+++ b/tex/context/base/mkiv/status-files.pdf
Binary files differ
diff --git a/tex/context/base/mkiv/status-lua.pdf b/tex/context/base/mkiv/status-lua.pdf
index 5a9ff773c..5e96fd065 100644
--- a/tex/context/base/mkiv/status-lua.pdf
+++ b/tex/context/base/mkiv/status-lua.pdf
Binary files differ
diff --git a/tex/context/base/mkiv/strc-lst.lua b/tex/context/base/mkiv/strc-lst.lua
index 1d2a8bb39..02b0c5b8c 100644
--- a/tex/context/base/mkiv/strc-lst.lua
+++ b/tex/context/base/mkiv/strc-lst.lua
@@ -1082,6 +1082,7 @@ implement {
implement {
name = "deferredenhancelist",
arguments = "integer",
+ protected = true,
actions = function(n)
ctx_latelua(function() enhancelist(n) end)
end,
diff --git a/tex/context/base/mkiv/strc-ref.lua b/tex/context/base/mkiv/strc-ref.lua
index 951c9a44a..4f4820aae 100644
--- a/tex/context/base/mkiv/strc-ref.lua
+++ b/tex/context/base/mkiv/strc-ref.lua
@@ -456,6 +456,7 @@ references.enhance = enhancereference
implement {
name = "deferredenhancereference",
arguments = "2 strings",
+ protected = true,
actions = function(prefix,tag)
ctx_latelua(function() enhancereference(prefix,tag) end)
end,
diff --git a/tex/context/base/mkiv/strc-reg.lua b/tex/context/base/mkiv/strc-reg.lua
index 61e13e7e4..d01037a10 100644
--- a/tex/context/base/mkiv/strc-reg.lua
+++ b/tex/context/base/mkiv/strc-reg.lua
@@ -635,6 +635,7 @@ implement {
implement {
name = "deferredenhanceregister",
arguments = { "string", "integer" },
+ protected = true,
actions = function(name,n)
ctx_latelua(function() enhanceregister(name,n) end)
end,
diff --git a/tex/context/base/mkiv/typo-mar.lua b/tex/context/base/mkiv/typo-mar.lua
index ab39f1808..b7288fd53 100644
--- a/tex/context/base/mkiv/typo-mar.lua
+++ b/tex/context/base/mkiv/typo-mar.lua
@@ -85,7 +85,6 @@ local setwidth = nuts.setwidth
local getheight = nuts.getheight
local getdata = nuts.getdata
-local currentattr = nuts.current_attr
local setattrlist = nuts.setattrlist
local getbox = nuts.getbox
@@ -303,7 +302,7 @@ function margins.save(t)
-- t.realpageno = texgetcount("realpageno")
if inline then
local n = new_usernumber(inline_mark,nofsaved)
- setattrlist(n,currentattr())
+ setattrlist(n,true)
context(tonode(n)) -- or use a normal node
store[nofsaved] = t -- no insert
nofinlined = nofinlined + 1
diff --git a/tex/context/interface/mkiv/i-context.pdf b/tex/context/interface/mkiv/i-context.pdf
index 7e43ed9cb..b1ac585f5 100644
--- a/tex/context/interface/mkiv/i-context.pdf
+++ b/tex/context/interface/mkiv/i-context.pdf
Binary files differ
diff --git a/tex/context/interface/mkiv/i-readme.pdf b/tex/context/interface/mkiv/i-readme.pdf
index c73529dcd..5b8acf1ca 100644
--- a/tex/context/interface/mkiv/i-readme.pdf
+++ b/tex/context/interface/mkiv/i-readme.pdf
Binary files differ
diff --git a/tex/context/modules/mkiv/s-youless.mkiv b/tex/context/modules/mkiv/s-youless.mkiv
index d8b6e2ff6..662025484 100644
--- a/tex/context/modules/mkiv/s-youless.mkiv
+++ b/tex/context/modules/mkiv/s-youless.mkiv
@@ -43,6 +43,7 @@
end
local year = tonumber(specification.year) or os.today().year
+ local month = tonumber(specification.month)
local years = data.years
local variant = data.variant
local unit = specification.unit
@@ -60,16 +61,19 @@
end
end
+ local firstmonth = month or 1
+ local lastmonth = month or 12
+
local max = max
local delta = round(max/10)
local scale = round(delta/20)
local mark = 3
for y=year,year do
- local year = years[y]
+ local year = years[y]
if year then
local grand = 0
- for m=1,12 do
+ for m=firstmonth,lastmonth do
local month = year.months[m]
if month then
context.startMPpage { offset = "10pt" }
diff --git a/tex/generic/context/luatex/luatex-fonts-merged.lua b/tex/generic/context/luatex/luatex-fonts-merged.lua
index d37e64216..4776e2cb0 100644
--- a/tex/generic/context/luatex/luatex-fonts-merged.lua
+++ b/tex/generic/context/luatex/luatex-fonts-merged.lua
@@ -1,6 +1,6 @@
-- merged file : c:/data/develop/context/sources/luatex-fonts-merged.lua
-- parent file : c:/data/develop/context/sources/luatex-fonts.lua
--- merge date : 08/16/18 10:17:32
+-- merge date : 08/19/18 12:52:28
do -- begin closure to overcome local limits and interference
@@ -20900,9 +20900,9 @@ function readers.getcomponents(fontdata)
end
end
for i=1,#steps do
- local coverage=steps[i].coverage
- if coverage then
- for k,v in next,coverage do
+ local c=steps[i].coverage
+ if c then
+ for k,v in next,c do
traverse(k,k,v)
end
end
@@ -21969,9 +21969,12 @@ local function mergesteps_1(lookup,strict)
report("merging %a steps of %a lookup %a",nofsteps,lookup.type,lookup.name)
local target=first.coverage
for i=2,nofsteps do
- for k,v in next,steps[i].coverage do
- if not target[k] then
- target[k]=v
+ local c=steps[i].coverage
+ if c then
+ for k,v in next,c do
+ if not target[k] then
+ target[k]=v
+ end
end
end
end
@@ -21996,16 +21999,19 @@ local function mergesteps_2(lookup)
report("merging %a steps of %a lookup %a",nofsteps,lookup.type,lookup.name)
local target=first.coverage
for i=2,nofsteps do
- for k,v in next,steps[i].coverage do
- local tk=target[k]
- if tk then
- for kk,vv in next,v do
- if tk[kk]==nil then
- tk[kk]=vv
+ local c=steps[i].coverage
+ if c then
+ for k,v in next,c do
+ local tk=target[k]
+ if tk then
+ for kk,vv in next,v do
+ if tk[kk]==nil then
+ tk[kk]=vv
+ end
end
+ else
+ target[k]=v
end
- else
- target[k]=v
end
end
end
@@ -22020,13 +22026,16 @@ local function mergesteps_3(lookup,strict)
report("merging %a steps of %a lookup %a",nofsteps,lookup.type,lookup.name)
local coverage={}
for i=1,nofsteps do
- for k,v in next,steps[i].coverage do
- local tk=coverage[k]
- if tk then
- report("quitting merge due to multiple checks")
- return nofsteps
- else
- coverage[k]=v
+ local c=steps[i].coverage
+ if c then
+ for k,v in next,c do
+ local tk=coverage[k]
+ if tk then
+ report("quitting merge due to multiple checks")
+ return nofsteps
+ else
+ coverage[k]=v
+ end
end
end
end
@@ -22072,12 +22081,15 @@ local function mergesteps_4(lookup)
report("merging %a steps of %a lookup %a",nofsteps,lookup.type,lookup.name)
local target=first.coverage
for i=2,nofsteps do
- for k,v in next,steps[i].coverage do
- local tk=target[k]
- if tk then
- nested(v,tk)
- else
- target[k]=v
+ local c=steps[i].coverage
+ if c then
+ for k,v in next,c do
+ local tk=target[k]
+ if tk then
+ nested(v,tk)
+ else
+ target[k]=v
+ end
end
end
end
@@ -22097,18 +22109,21 @@ local function mergesteps_5(lookup)
break
end
for i=2,nofsteps do
- for k,v in next,steps[i].coverage do
- local tk=target[k]
- if tk then
- if not tk[2] then
- tk[2]=v[2]
- end
- if not tk[3] then
- tk[3]=v[3]
+ local c=steps[i].coverage
+ if c then
+ for k,v in next,c do
+ local tk=target[k]
+ if tk then
+ if not tk[2] then
+ tk[2]=v[2]
+ end
+ if not tk[3] then
+ tk[3]=v[3]
+ end
+ else
+ target[k]=v
+ v[1]=hash
end
- else
- target[k]=v
- v[1]=hash
end
end
end