[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Can't interrupt tight loops in Lua 5.4 anymore?
- From: Roberto Ierusalimschy <roberto@...>
- Date: Mon, 25 May 2020 13:02:49 -0300
> The documentation says that lua_sethook "can be called asynchronously
> (e.g. during a signal)",
This is written in an internal comment, which is not part of the official
documentation.
> but if it's called from a signal handler that
> runs at just the "right" time (after a CallInfo gets created but
> before it gets linked into L->ci), and the currently running Lua code
> happens to be the "right" kind of infinite loop, then the hook
> function will never get called. As such, I'd consider it a bug,
> especially since you could rely on this working right in Lua 5.3.
If the signal happens after a CallInfo gets created but before it gets
linked into L->ci, then the code still have to enter the function,
which will call the 'call' hook. I don't see any bug here.
-- Roberto
- References:
- Re: Can't interrupt tight loops in Lua 5.4 anymore?, Joseph C. Sible
- Re: Can't interrupt tight loops in Lua 5.4 anymore?, Viacheslav Usov
- Re: Can't interrupt tight loops in Lua 5.4 anymore?, Joseph C. Sible
- Re: Can't interrupt tight loops in Lua 5.4 anymore?, Viacheslav Usov
- Re: Can't interrupt tight loops in Lua 5.4 anymore?, Joseph C. Sible
- Re: Can't interrupt tight loops in Lua 5.4 anymore?, Viacheslav Usov
- Re: Can't interrupt tight loops in Lua 5.4 anymore?, Roberto Ierusalimschy
- Re: Can't interrupt tight loops in Lua 5.4 anymore?, Joseph C. Sible
- Re: Can't interrupt tight loops in Lua 5.4 anymore?, Roberto Ierusalimschy
- Re: Can't interrupt tight loops in Lua 5.4 anymore?, Joseph C. Sible