[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Count excuted bytecodes
- From: Luiz Henrique de Figueiredo <lhf@...>
- Date: Wed, 5 Feb 2003 22:14:41 -0200
>I need to be able to determine in a predictable way if a program are
>'too big', is it possible to do that with Lua by counting how many
>bytecodes a program have executed and stop it after a certain number?
In Lua 5.0, yes: you can set a count hook for the max number of instructions
allowed and call error in it to stop the program.
--lhf