summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorHans Hagen <pragma@wxs.nl>2010-09-22 09:35:00 +0200
committerHans Hagen <pragma@wxs.nl>2010-09-22 09:35:00 +0200
commitd0b8d7f9a7f3d423f750c0078cc1d906de14b939 (patch)
treef4f0f84187f82602468dae7113b7cce7e568fcf2 /scripts
parent1b0f23b6023d92d5436a01ba4e2171ff7e0a70f6 (diff)
downloadcontext-d0b8d7f9a7f3d423f750c0078cc1d906de14b939.tar.gz
beta 2010.09.22 09:35
Diffstat (limited to 'scripts')
-rw-r--r--scripts/context/lua/mtxrun.lua6
-rw-r--r--scripts/context/stubs/mswin/mtxrun.lua6
-rwxr-xr-xscripts/context/stubs/unix/mtxrun6
3 files changed, 12 insertions, 6 deletions
diff --git a/scripts/context/lua/mtxrun.lua b/scripts/context/lua/mtxrun.lua
index b175a35a4..622643f9c 100644
--- a/scripts/context/lua/mtxrun.lua
+++ b/scripts/context/lua/mtxrun.lua
@@ -615,7 +615,7 @@ local function sortedkeys(tab)
elseif tkey == "number" then
-- if kind == 1 then kind = 3 else kind = 2 end
kind = (kind == 1 and 3) or 2
- else
+ else -- if tkey then
kind = 3
end
end
@@ -631,7 +631,9 @@ end
local function sortedhashkeys(tab) -- fast one
local srt = { }
for key,_ in next, tab do
- srt[#srt+1] = key
+ if key then
+ srt[#srt+1] = key
+ end
end
sort(srt)
return srt
diff --git a/scripts/context/stubs/mswin/mtxrun.lua b/scripts/context/stubs/mswin/mtxrun.lua
index b175a35a4..622643f9c 100644
--- a/scripts/context/stubs/mswin/mtxrun.lua
+++ b/scripts/context/stubs/mswin/mtxrun.lua
@@ -615,7 +615,7 @@ local function sortedkeys(tab)
elseif tkey == "number" then
-- if kind == 1 then kind = 3 else kind = 2 end
kind = (kind == 1 and 3) or 2
- else
+ else -- if tkey then
kind = 3
end
end
@@ -631,7 +631,9 @@ end
local function sortedhashkeys(tab) -- fast one
local srt = { }
for key,_ in next, tab do
- srt[#srt+1] = key
+ if key then
+ srt[#srt+1] = key
+ end
end
sort(srt)
return srt
diff --git a/scripts/context/stubs/unix/mtxrun b/scripts/context/stubs/unix/mtxrun
index b175a35a4..622643f9c 100755
--- a/scripts/context/stubs/unix/mtxrun
+++ b/scripts/context/stubs/unix/mtxrun
@@ -615,7 +615,7 @@ local function sortedkeys(tab)
elseif tkey == "number" then
-- if kind == 1 then kind = 3 else kind = 2 end
kind = (kind == 1 and 3) or 2
- else
+ else -- if tkey then
kind = 3
end
end
@@ -631,7 +631,9 @@ end
local function sortedhashkeys(tab) -- fast one
local srt = { }
for key,_ in next, tab do
- srt[#srt+1] = key
+ if key then
+ srt[#srt+1] = key
+ end
end
sort(srt)
return srt