diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2000-03-09 10:57:37 -0300 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2000-03-09 10:57:37 -0300 |
commit | e3cf93ddb677fe9482563a5687d3bf3e05ca0407 (patch) | |
tree | c692a19e5597c785c198d558a07dd0571f3fa98c /lparser.h | |
parent | 88b306f495fa7034c708c6b75a355a6deee51c58 (diff) | |
download | lua-e3cf93ddb677fe9482563a5687d3bf3e05ca0407.tar.gz lua-e3cf93ddb677fe9482563a5687d3bf3e05ca0407.tar.bz2 lua-e3cf93ddb677fe9482563a5687d3bf3e05ca0407.zip |
first implementation of "threaded code" for boolean operations
Diffstat (limited to 'lparser.h')
-rw-r--r-- | lparser.h | 14 |
1 files changed, 10 insertions, 4 deletions
@@ -47,15 +47,21 @@ | |||
47 | */ | 47 | */ |
48 | 48 | ||
49 | typedef enum { | 49 | typedef enum { |
50 | VGLOBAL, /* info is constant index of global name */ | 50 | VGLOBAL, |
51 | VLOCAL, /* info is stack index */ | 51 | VLOCAL, |
52 | VINDEXED, | 52 | VINDEXED, |
53 | VEXP /* info is jump target if exp has internal jumps */ | 53 | VEXP |
54 | } expkind; | 54 | } expkind; |
55 | 55 | ||
56 | typedef struct expdesc { | 56 | typedef struct expdesc { |
57 | expkind k; | 57 | expkind k; |
58 | int info; | 58 | union { |
59 | int index; /* VGLOBAL: `kstr' index of global name; VLOCAL: stack index */ | ||
60 | struct { | ||
61 | int t; /* patch list of `exit when true' */ | ||
62 | int f; /* patch list of `exit when false' */ | ||
63 | } l; | ||
64 | } u; | ||
59 | } expdesc; | 65 | } expdesc; |
60 | 66 | ||
61 | 67 | ||