From f2a20e191bf71094aa21d37dee2ecd2f804dbc56 Mon Sep 17 00:00:00 2001 From: Hans Hagen Date: Thu, 20 Apr 2017 22:56:41 +0200 Subject: 2017-04-20 21:37:00 --- tex/context/base/mkiv/l-table.lua | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) (limited to 'tex/context/base/mkiv/l-table.lua') diff --git a/tex/context/base/mkiv/l-table.lua b/tex/context/base/mkiv/l-table.lua index 5deb795d1..6bb0ef637 100644 --- a/tex/context/base/mkiv/l-table.lua +++ b/tex/context/base/mkiv/l-table.lua @@ -573,7 +573,12 @@ local function is_simple_table(t) -- also used in util-tab so maybe public local v = t[i] local tv = type(v) if tv == "number" then - tt[i] = v -- not needed tostring(v) + -- tt[i] = v -- not needed tostring(v) + if hexify then + tt[i] = format("0x%X",v) + else + tt[i] = v -- not needed tostring(v) + end elseif tv == "string" then tt[i] = format("%q",v) -- f_string(v) elseif tv == "boolean" then @@ -589,7 +594,12 @@ local function is_simple_table(t) -- also used in util-tab so maybe public local v = t[i] local tv = type(v) if tv == "number" then - tt[i+1] = v -- not needed tostring(v) + -- tt[i+1] = v -- not needed tostring(v) + if hexify then + tt[i+1] = format("0x%X",v) + else + tt[i+1] = v -- not needed tostring(v) + end elseif tv == "string" then tt[i+1] = format("%q",v) -- f_string(v) elseif tv == "boolean" then -- cgit v1.2.3