summaryrefslogtreecommitdiff
path: root/tex/context/base/mkiv/supp-ran.lua
diff options
context:
space:
mode:
Diffstat (limited to 'tex/context/base/mkiv/supp-ran.lua')
-rw-r--r--tex/context/base/mkiv/supp-ran.lua14
1 files changed, 7 insertions, 7 deletions
diff --git a/tex/context/base/mkiv/supp-ran.lua b/tex/context/base/mkiv/supp-ran.lua
index 08889edf3..03da4262f 100644
--- a/tex/context/base/mkiv/supp-ran.lua
+++ b/tex/context/base/mkiv/supp-ran.lua
@@ -80,7 +80,8 @@ end
-- maybe stack
local function pushrandomseed()
- insert(stack,last)
+ -- insert(stack,last) -- doesn't work okay
+ insert(stack,randomseed(last) or last)
if trace_random or trace_details then
report_system("pushing seed %s",last)
end
@@ -141,10 +142,9 @@ utilities.randomizer = {
implement { name = "getrandomnumber", actions = { getrandomnumber, context }, arguments = { "integer", "integer" } }
implement { name = "getrandomdimen", actions = { getrandomnumber, context }, arguments = { "dimen", "dimen" } }
implement { name = "getrandomfloat", actions = { getrandomnumber, context }, arguments = { "number", "number" } }
---------- { name = "getmprandomnumber", actions = { getmprandomnumber, context } }
-implement { name = "setrandomseed", actions = { setrandomseed }, arguments = "integer" }
-implement { name = "getrandomseed", actions = { getrandomseed, context } }
-implement { name = "pushrandomseed", actions = { pushrandomseed } }
-implement { name = "poprandomseed", actions = { poprandomseed } }
-implement { name = "reuserandomseed", actions = { reuserandomseed } }
+implement { name = "getrandomseed", actions = { getrandomseed, context } }
+implement { name = "setrandomseed", actions = setrandomseed, arguments = "integer" }
+implement { name = "pushrandomseed", actions = pushrandomseed, public = true, }
+implement { name = "poprandomseed", actions = poprandomseed, public = true, }
+implement { name = "reuserandomseed", actions = reuserandomseed, public = true, }