[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Detecting an "empty" script?
- From: Ando Sonenblick <ando@...>
- Date: Thu, 21 Aug 2003 10:48:07 -0700
Gang,
I need to determine if a Lua script does something -- anything -- nor not.
For example, this script does nothing:
"function main(arg)
end"
While this one does:
"x = 4"
I know I can technically parse the text of the script to determine if it
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? I'm
thinking that once the script is compiled, one could quickly scan it for any
"set" opcodes and such?
Any thoughts?
Thx,
Ando
-----------------
SpriTec Software
www.spritec.com