3

I'm working on a LuaLaTeX-Document project using my laptop and a desktop PC. The document contains a LuaLaTeX script to enable C-Style comments (link). However, while compilation works fine on my laptop, on the desktop PC the error

! LuaTeX error ./cStyleComments.lua:30: attempt to index global 'luatexbase' (a 
nil value)
stack traceback:
    ./cStyleComments.lua:30: in main chunk
    [C]: in function 'require'
    [\directlua]:1: in main chunk.
l.24 \directlua{require("cStyleComments.lua")}

occurs.

cStyleComments.lua contains the definition of comments method and line 30, which reads:

luatexbase.add_to_callback('process_input_buffer', comment, 'comment')

LuaLaTeX version on laptop: beta-0.80.0
LuaLaTeX version on PC: beta-0.79.1 (I have no sudo, so I cannot upgrade).

1 Answer 1

3

The solution was to use the luatexbase package:

\usepackage{luatexbase}

However I don't know why it works without on the laptop system.

2
  • I may be wrong, but perhaps this is caused by one of your systems not to have the latest packages versions?
    – Moriambar
    Commented Apr 10, 2017 at 12:36
  • 2
    the code from luatexbase has been added to the kernel in a newer latex. Commented Apr 10, 2017 at 13:13

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .