action handling: add test to avoid direct access

Direct access to the action field of Packet structure is not
allowed.
pull/392/head
Eric Leblond 12 years ago committed by Victor Julien
parent a35c367942
commit ce95fbdda0

@ -0,0 +1,15 @@
@action@
typedef Packet;
Packet *p;
position p1;
@@
p->action@p1
@ script:python @
p1 << action.p1;
@@
print "Invalid usage of p->action, please use macro at %s:%s" % (p1[0].file, p1[0].line)
import sys
sys.exit(1)
Loading…
Cancel
Save