summaryrefslogtreecommitdiff
path: root/Build/source/texk/web2c/luatexdir
diff options
context:
space:
mode:
authorLuigi Scarso <luigi.scarso@gmail.com>2022-02-28 19:21:33 +0000
committerLuigi Scarso <luigi.scarso@gmail.com>2022-02-28 19:21:33 +0000
commitcacf51e610724305b9d8204b79b91ee43d080b0d (patch)
tree77e73b8aa4d6a26716f328e7f24401e088d52f9b /Build/source/texk/web2c/luatexdir
parent261b21b282c2f404b398f252668a084489c001b0 (diff)
LuaTeX: pass node to latelua function call (H.Hagen).
git-svn-id: svn://tug.org/texlive/trunk@62281 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/texk/web2c/luatexdir')
-rw-r--r--Build/source/texk/web2c/luatexdir/ChangeLog3
-rw-r--r--Build/source/texk/web2c/luatexdir/lua/luastuff.c9
-rw-r--r--Build/source/texk/web2c/luatexdir/luatex_svnversion.h2
3 files changed, 9 insertions, 5 deletions
diff --git a/Build/source/texk/web2c/luatexdir/ChangeLog b/Build/source/texk/web2c/luatexdir/ChangeLog
index 0eb46e3f13e..0ee4a15d0c9 100644
--- a/Build/source/texk/web2c/luatexdir/ChangeLog
+++ b/Build/source/texk/web2c/luatexdir/ChangeLog
@@ -1,3 +1,6 @@
+2022-02-28 Luigi Scarso <luigi.scarso@gmail.com>
+ * pass node to latelua function call (H.Hagen)
+
2022-02-27 Luigi Scarso <luigi.scarso@gmail.com>
* Development id also with --version.
diff --git a/Build/source/texk/web2c/luatexdir/lua/luastuff.c b/Build/source/texk/web2c/luatexdir/lua/luastuff.c
index fb05c60dd1f..feb6a88c8bf 100644
--- a/Build/source/texk/web2c/luatexdir/lua/luastuff.c
+++ b/Build/source/texk/web2c/luatexdir/lua/luastuff.c
@@ -442,7 +442,7 @@ int lua_traceback(lua_State * L)
return 1;
}
-static void luacall(int p, int nameptr, boolean is_string)
+static void luacall(int p, int nameptr, boolean is_string, halfword w)
{
LoadS ls;
int i;
@@ -466,7 +466,8 @@ static void luacall(int p, int nameptr, boolean is_string)
/*tex put it under chunk */
lua_insert(Luas, base);
++late_callback_count;
- i = lua_pcall(Luas, 0, 0, base);
+ lua_nodelib_push_fast(Luas, w);
+ i = lua_pcall(Luas, 1, 0, base);
/*tex remove traceback function */
lua_remove(Luas, base);
if (i != 0) {
@@ -600,12 +601,12 @@ void late_lua(PDF pdf, halfword p)
if (t == normal) {
/*tex sets |def_ref| */
expand_macros_in_tokenlist(p);
- luacall(def_ref, late_lua_name(p), false);
+ luacall(def_ref, late_lua_name(p), false, p);
flush_list(def_ref);
} else if (t == lua_refid_call) {
luafunctioncall(late_lua_data(p));
} else if (t == lua_refid_literal) {
- luacall(late_lua_data(p), late_lua_name(p), true);
+ luacall(late_lua_data(p), late_lua_name(p), true, p);
} else {
/*tex Let's just ignore it, could be some user specific thing. */
}
diff --git a/Build/source/texk/web2c/luatexdir/luatex_svnversion.h b/Build/source/texk/web2c/luatexdir/luatex_svnversion.h
index c6864a4aeae..ced5e39e06e 100644
--- a/Build/source/texk/web2c/luatexdir/luatex_svnversion.h
+++ b/Build/source/texk/web2c/luatexdir/luatex_svnversion.h
@@ -1,4 +1,4 @@
#ifndef luatex_svn_revision_h
#define luatex_svn_revision_h
-#define luatex_svn_revision 7501
+#define luatex_svn_revision 7503
#endif