[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: RE: Detecting an "empty" script?
- From: "Nick Trout" <nick@...>
- Date: Thu, 21 Aug 2003 12:49:48 -0700
Couldn't you put a line hook on the code and count calls to that?
> -----Original Message-----
> From: Ando Sonenblick [mailto:firstname.lastname@example.org]
> Sent: Thursday, August 21, 2003 10:48 AM
> To: Lua list
> Subject: Detecting an "empty" script?
> I need to determine if a Lua script does something -- anything -- nor
> For example, this script does nothing:
> "function main(arg)
> While this one does:
> "x = 4"
> I know I can technically parse the text of the script to determine if
> will do anything or not, but that seems like a lot of work trying to
> decipher things.
> Is there a way that Lua can be convinced to determine this for me?
> thinking that once the script is compiled, one could quickly scan it
> "set" opcodes and such?
> Any thoughts?
> SpriTec Software