[lltx] patch for lualatex-math.lua

Wolfgang Jeltsch wolfgang at cs.ioc.ee
Fri Aug 16 13:18:56 CEST 2013


Hi,

I see that the patched package has been uploaded to CTAN. Surprisingly,
it hasn’t gone into TeX Live. Does anyone know why?

Best wishes,
Wolfgang

Am Samstag, den 03.08.2013, 23:28 +0200 schrieb Philipp Stephani:
> Thanks for the patch; I've already merged Philipp Gesang's equivalent
> patch and will do a new release ASAP.
> 
> 
> 2013/8/3 Wolfgang Jeltsch <wolfgang at cs.ioc.ee>
>         Hi Philipp,
>         
>         I don’t know if you have followed the recent discussion on
>         lualatex-dev
>         about an issue with the lualatex-math package.
>         
>         The code in lualatex-math.lua relies on unpack being a global
>         variable,
>         which was the case in Lua 5.1, but is not the case anymore in
>         Lua 5.2.
>         As a result, I get the following error when importing amsmath
>         and
>         lualatex-math in the same document:
>         
>             ! LuaTeX error
>         
>           .../texmf-dist/tex/lualatex/lualatex-math/lualatex-math.lua:46:
>             attempt to call upvalue 'unpack' (a nil value)
>             stack traceback:
>         
>           .../texmf-dist/tex/lualatex/lualatex-math/lualatex-math.lua:46:
>                     in function 'print_class_fam_slot'
>                     [string "\directlua "]:1: in main chunk.
>             \__lltxmath_set_mathchar:NN ...\int_eval:n {`#2})}
>         
>         \scan_stop:
>         
>         Other Lua files (lualibs-basic-merged.lua, lualibs-lua.lua,
>         and
>         luaotfload-merged.lua) use the following code to work around
>         this
>         incompatibility between Lua 5.1 and Lua 5.2:
>         
>             if not table.unpack then
>               table.unpack=_G.unpack
>             elseif not unpack then
>               _G.unpack=table.unpack
>             end
>         
>         By adding this code to lualatex-math.lua at an appropriate
>         place, I was
>         able to fix the issue with lualatex-math and amsmath.
>         
>         I’ve attached a patch. Could this patch or some other fix for
>         the
>         problem please be incorporated into lualatex-math? Thank you.
>         
>         Best wishes,
>         Wolfgang
> 
> 




More information about the lualatex-dev mailing list