[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: LUA 5.0 Debugging Problem
- From: Luiz Henrique de Figueiredo <lhf@...>
- Date: Mon, 12 Jan 2004 08:57:09 -0200
>It seems that the LUA_HOOKLINE event is not called for the first line of
>this simple program:
>
>line 1:print("Hello world");
>line 2:io.read(1);
It works if the line hook is set in a separate chunk:
% cat h
debug.sethook(print,"l")
% cat i
print("Hello world");
io.read(1);
% lua -lh i
line 1
Hello world
line 2
[wait for read...]
It does not work if the sethook is called in the same chunk:
% cat j
debug.sethook(print,"l")
print("Hello world");
io.read(1);
% lua j
Hello world
line 3
[wait for read...]
--lhf