[latex3-commits] [git/LaTeX3-latex3-luaotfload] dev: Case-insensitive script matching in multiscript (efc2ad0)
Marcel Fabian Krüger
tex at 2krueger.de
Sun Jan 26 13:37:12 CET 2020
Repository : https://github.com/latex3/luaotfload
On branch : dev
Link : https://github.com/latex3/luaotfload/commit/efc2ad08794756ea74037a348e62edadd2dd9c06
>---------------------------------------------------------------
commit efc2ad08794756ea74037a348e62edadd2dd9c06
Author: Marcel Fabian Krüger <tex at 2krueger.de>
Date: Sun Jan 26 13:33:02 2020 +0100
Case-insensitive script matching in multiscript
>---------------------------------------------------------------
efc2ad08794756ea74037a348e62edadd2dd9c06
src/luaotfload-multiscript.lua | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/src/luaotfload-multiscript.lua b/src/luaotfload-multiscript.lua
index f9585d6..bc513ed 100644
--- a/src/luaotfload-multiscript.lua
+++ b/src/luaotfload-multiscript.lua
@@ -195,7 +195,15 @@ local function makecombifont(tfmdata, _, additional_scripts)
if additional_scripts then
local t = additional_scripts_tables[tonumber(additional_scripts) or additional_scripts]
if not t then error(string.format("Unknown multiscript table %s", additional_scripts)) end
- additional_scripts = table.merged(t)
+ local lower_t = {}
+ for k, v in next, t do if type(k) == "string" then
+ local l = string.lower(k)
+ if lower_t[l] ~= nil and lower_t[l] ~= v then
+ error(string.format("Inconsistant multiscript table %q for script %s", additional_scripts, l))
+ end
+ lower_t[l] = v
+ end end
+ additional_scripts = lower_t
else
additional_scripts = {}
end
More information about the latex3-commits
mailing list