summaryrefslogtreecommitdiff
path: root/tex/context/base/mkiv/char-ini.lua
diff options
context:
space:
mode:
authorHans Hagen <pragma@wxs.nl>2018-09-02 00:04:51 +0200
committerContext Git Mirror Bot <phg@phi-gamma.net>2018-09-02 00:04:51 +0200
commitfd9c4ecd4421d087de21bef1e53d8ffb016285b0 (patch)
tree64606204adcabe2f197984ca8d063891b770bace /tex/context/base/mkiv/char-ini.lua
parent2106beefbc854f77a92264c815d3cf2b3460f0b6 (diff)
downloadcontext-fd9c4ecd4421d087de21bef1e53d8ffb016285b0.tar.gz
2018-09-01 23:20:00
Diffstat (limited to 'tex/context/base/mkiv/char-ini.lua')
-rw-r--r--tex/context/base/mkiv/char-ini.lua11
1 files changed, 4 insertions, 7 deletions
diff --git a/tex/context/base/mkiv/char-ini.lua b/tex/context/base/mkiv/char-ini.lua
index 92f9a2291..ea9aa330f 100644
--- a/tex/context/base/mkiv/char-ini.lua
+++ b/tex/context/base/mkiv/char-ini.lua
@@ -645,22 +645,19 @@ function characters.getrange(name,expression) -- used in font fallback definitio
local first, rest = lpegmatch(splitter2,name)
local range = rawget(blocks,lower(gsub(first,"[^a-zA-Z0-9]","")))
if range then
- start = range.first
- stop = range.last
local s = loadstring("return 0 " .. rest)
if type(s) == "function" then
local d = s()
if type(d) == "number" then
- start = start + d
- stop = stop + d
- return start, stop, nil
+ return range.first + d, range.last + d, nil
end
end
end
end
- start, stop = lpegmatch(splitter1,name)
+ local start, stop = lpegmatch(splitter1,name)
if start and stop then
- start, stop = tonumber(start,16) or tonumber(start), tonumber(stop,16) or tonumber(stop)
+ start = tonumber(start,16) or tonumber(start)
+ stop = tonumber(stop, 16) or tonumber(stop)
if start and stop then
return start, stop, nil
end