[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: catching lua variable set and get value
- From: ivano.coltellacci@...
- Date: Wed, 25 Jun 2003 05:03:57 +0200 (CEST)
I'd like to be able to intercept set/get of value to
Lets me explain with an example. Each time the 'sym'
variable is used as lvalue or it is evaluated into an
expression, id like to call back some piece of 'C'
sym = 10
in this case id like the callback to receive something
like: myLvalueCallback(sring varName, double value)
a = sym
in this case id like my callback return the value of
the sym. double myExprCallback(varName)
The purpose of this is to use lua as language for
a bench, the 'sym' variables will behave like port
to hardware specific registers...
the metatable have some features allowing the
catch of some events, but they dont seem be useful
to solve my problem...