summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/context/base/core-dat.lua
diff options
context:
space:
mode:
authorMojca Miklavec <mojca.miklavec@gmail.com>2014-05-05 20:29:55 +0000
committerMojca Miklavec <mojca.miklavec@gmail.com>2014-05-05 20:29:55 +0000
commitba9a57343987f1c2c72396e7c38f1fa30352c24c (patch)
tree66a8b12cdf67427ce96770fd0e9e581759aade1c /Master/texmf-dist/tex/context/base/core-dat.lua
parent15242121b8ddf7d4a041fb3998d295dd8232e1eb (diff)
ConTeXt 2014.04.28 23:24
git-svn-id: svn://tug.org/texlive/trunk@33856 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/context/base/core-dat.lua')
-rw-r--r--Master/texmf-dist/tex/context/base/core-dat.lua28
1 files changed, 14 insertions, 14 deletions
diff --git a/Master/texmf-dist/tex/context/base/core-dat.lua b/Master/texmf-dist/tex/context/base/core-dat.lua
index 826d3a675ee..242d362d0f6 100644
--- a/Master/texmf-dist/tex/context/base/core-dat.lua
+++ b/Master/texmf-dist/tex/context/base/core-dat.lua
@@ -21,13 +21,17 @@ local trace_pagestates = false trackers.register("job.pagestates", function(v)
local report_dataset = logs.reporter("dataset")
local report_pagestate = logs.reporter("pagestate")
-local allocate = utilities.storage.allocate
+local allocate = utilities.storage.allocate
local settings_to_hash = utilities.parsers.settings_to_hash
-local texcount = tex.count
-local formatters = string.formatters
-local v_yes = interfaces.variables.yes
-local new_latelua = nodes.pool.latelua
+local texgetcount = tex.getcount
+local texsetcount = tex.setcount
+
+local formatters = string.formatters
+
+local v_yes = interfaces.variables.yes
+
+local new_latelua = nodes.pool.latelua
local collected = allocate()
local tobesaved = allocate()
@@ -86,7 +90,7 @@ local function setdata(settings)
set.index = index
data.index = index
data.order = index
- data.realpage = texcount.realpageno
+ data.realpage = texgetcount("realpageno")
if trace_datasets then
report_dataset("action %a, name %a, tag %a, index %a","assign delayed",name,tag,index)
end
@@ -101,7 +105,7 @@ datasets.setdata = setdata
function datasets.extend(name,tag)
local set = sets[name]
local order = set.order + 1
- local realpage = texcount.realpageno
+ local realpage = texgetcount("realpageno")
set.order = order
local t = tobesaved[name][tag]
t.realpage = realpage
@@ -207,7 +211,7 @@ local function setstate(settings)
else
tag = tonumber(tag) or tag -- autonumber saves keys
end
- local realpage = texcount.realpageno
+ local realpage = texgetcount("realpageno")
local data = realpage
list[tag] = data
if trace_pagestates then
@@ -219,7 +223,7 @@ end
pagestates.setstate = setstate
function pagestates.extend(name,tag)
- local realpage = texcount.realpageno
+ local realpage = texgetcount("realpageno")
if trace_pagestates then
report_pagestate("action %a, name %a, tag %a, preset %a","synchronize",name,tag,realpage)
end
@@ -261,9 +265,5 @@ end
function commands.setpagestaterealpageno(name,tag)
local t = collected[name]
t = t and (t[tag] or t[tonumber(tag)])
- if t then
- texcount.realpagestateno = t
- else
- texcount.realpagestateno = texcount.realpageno
- end
+ texsetcount("realpagestateno",t or texgetcount("realpageno"))
end