summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/source/latex/ucharcat
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2015-11-20 23:16:05 +0000
committerKarl Berry <karl@freefriends.org>2015-11-20 23:16:05 +0000
commitaf275c7f6fca66b476804270863d1a5e971cb956 (patch)
tree2babc0b07e29ab306dabc2d3d53da58f772c3cd5 /Master/texmf-dist/source/latex/ucharcat
parentd092745105741bf835e2735a9d93e8775c70d1ce (diff)
ucharcat (20nov15)
git-svn-id: svn://tug.org/texlive/trunk@38907 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/source/latex/ucharcat')
-rw-r--r--Master/texmf-dist/source/latex/ucharcat/ucharcat.dtx16
1 files changed, 8 insertions, 8 deletions
diff --git a/Master/texmf-dist/source/latex/ucharcat/ucharcat.dtx b/Master/texmf-dist/source/latex/ucharcat/ucharcat.dtx
index 1f8dd13c629..a5b06392c5c 100644
--- a/Master/texmf-dist/source/latex/ucharcat/ucharcat.dtx
+++ b/Master/texmf-dist/source/latex/ucharcat/ucharcat.dtx
@@ -13,7 +13,7 @@
%<driver> \ProvidesFile{ucharcat.drv}
% \fi
% \ProvidesFile{ucharcat.dtx}
- [2015/08/23 v0.02 ucharcat for luaLaTeX (DPC)]
+ [2015/11/19 v0.03 ucharcat for luaLaTeX (DPC)]
%
% \iffalse
%<*driver>
@@ -103,13 +103,12 @@
%
% Note that the current implementation uses |\directlua| and a
% dedicated luatex catcode array. Hans hagen made some useful comments
-% and pointers to alternative implementation using |\lusfunction|
+% and pointers to alternative implementation using |\luafunction|
% in the luatex list thread
% \texttt{http://tug.org/pipermail/luatex/2015-May/005199.html}
% For now keeping with the simpler initial approach as there
% is no built in support for |\luafunction| in the \LaTeX\ format yet.
-% (No allocator macros or hook to save function definition in the
-% format)
+% (No hook to save function definition in the format)
%
% \begin{macrocode}
%<*package>
@@ -132,8 +131,8 @@
\fi
% \end{macrocode}
%
-% If some package has defined an allocator for catcode tables
-% use it, othewise just use one (near) the top of the range (hex 7FFF).
+% Current latex formats (from 2015/11/01) define an allocator for catcode tables
+% otherwise just use one (near) the top of the range (hex 7FFF).
%
% \begin{macrocode}
\ifx\newcatcodetable\@undefined
@@ -149,9 +148,10 @@
% lua print function
% \begin{macrocode}
\directlua{%
+local nt = newtoken or token
function UcharcatLua()
- local mych = newtoken.scan_int()
- local mycat = newtoken.scan_int()
+ local mych = nt.scan_int()
+ local mycat = nt.scan_int()
tex.setcatcode(\the\numexpr\ucharcat@table\relax,mych,mycat)
tex.sprint(\the\numexpr\ucharcat@table\relax,unicode.utf8.char(mych))
end