[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: struct Proto.lineinfo difference between Lua 5.3 and 5.4
- From: Roberto Ierusalimschy <roberto@...>
- Date: Wed, 20 Oct 2021 11:01:28 -0300
> I have some code coverage code I used with Lua 5.3 that no longer works
> with 5.4. I am trying to wrap my head around the new Proto structure.
> The original 5.3 compatible recursive code used lineinfo as follows:
> How do I make the above compatible with 5.4?
If I understood correctly your question, I think the function you want
is already present in Lua: 'collectvalidlines', in file ldebug.c (except
that it does not traverse nested functions recursively).