From 77cef1d14e947b4899f54ca0311ca5ce9d253164 Mon Sep 17 00:00:00 2001 From: Norbert Preining Date: Sun, 22 Sep 2019 03:01:01 +0000 Subject: CTAN sync 201909220301 --- indexing/xindex/lualatex/xindex-lib.lua | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) (limited to 'indexing/xindex/lualatex/xindex-lib.lua') diff --git a/indexing/xindex/lualatex/xindex-lib.lua b/indexing/xindex/lualatex/xindex-lib.lua index 0dc6105910..90e5066896 100644 --- a/indexing/xindex/lualatex/xindex-lib.lua +++ b/indexing/xindex/lualatex/xindex-lib.lua @@ -7,7 +7,7 @@ ----------------------------------------------------------------------- if not modules then modules = { } end modules ['xindex-lib'] = { - version = 0.13, + version = 0.15, comment = "main library to xindex.lua", author = "Herbert Voss", copyright = "Herbert Voss", @@ -501,7 +501,7 @@ function get_category(code_point) end function getCharType(c) --- print ("getCharType c="..c..": codepoint="..utf8.codepoint(c)) +-- print ("getCharType c="..tostring(c).." "..type(c)..": codepoint="..utf8.codepoint(c)) local category = get_category(utf8.codepoint(c)) -- print ("getCharType: "..category) if category == "Nd" then return 1 @@ -739,11 +739,12 @@ function printList(Index,level) end function getItem(str,n) - if n >= 0 then + + if (n >= 0) and str then local item = (str:gsub("!.*", "%0!") :gsub("[^!]*!", "", n) :match("^([^!]*)!") ) - writeLog(1,"getItem ("..str..", "..n..") = "..item.."\n",2) +-- writeLog(1,"getItem ("..str..", "..n..") = "..item.."\n",2) return item end end @@ -977,8 +978,3 @@ function stripLeadingSpaces(str) return str:gsub("^%s*(.-)%s*$", "%1") end - - str:gsub("^%s*(.-)%s*$", "%1") -end - - -- cgit v1.2.3