diff options
Diffstat (limited to '')
| -rw-r--r-- | fallback.c | 21 |
1 files changed, 11 insertions, 10 deletions
| @@ -3,7 +3,7 @@ | |||
| 3 | ** TecCGraf - PUC-Rio | 3 | ** TecCGraf - PUC-Rio |
| 4 | */ | 4 | */ |
| 5 | 5 | ||
| 6 | char *rcs_fallback="$Id: fallback.c,v 1.13 1995/10/02 17:03:33 roberto Exp roberto $"; | 6 | char *rcs_fallback="$Id: fallback.c,v 1.14 1995/10/04 14:20:26 roberto Exp roberto $"; |
| 7 | 7 | ||
| 8 | #include <stdio.h> | 8 | #include <stdio.h> |
| 9 | #include <string.h> | 9 | #include <string.h> |
| @@ -28,15 +28,16 @@ static void funcFB (void); | |||
| 28 | ** Warning: This list must be in the same order as the #define's | 28 | ** Warning: This list must be in the same order as the #define's |
| 29 | */ | 29 | */ |
| 30 | struct FB luaI_fallBacks[] = { | 30 | struct FB luaI_fallBacks[] = { |
| 31 | {"error", {LUA_T_CFUNCTION, {errorFB}}}, | 31 | {"error", {LUA_T_CFUNCTION, {errorFB}}, 1, 0}, |
| 32 | {"index", {LUA_T_CFUNCTION, {indexFB}}}, | 32 | {"index", {LUA_T_CFUNCTION, {indexFB}}, 2, 1}, |
| 33 | {"gettable", {LUA_T_CFUNCTION, {gettableFB}}}, | 33 | {"gettable", {LUA_T_CFUNCTION, {gettableFB}}, 2, 1}, |
| 34 | {"arith", {LUA_T_CFUNCTION, {arithFB}}}, | 34 | {"arith", {LUA_T_CFUNCTION, {arithFB}}, 3, 1}, |
| 35 | {"order", {LUA_T_CFUNCTION, {orderFB}}}, | 35 | {"order", {LUA_T_CFUNCTION, {orderFB}}, 3, 1}, |
| 36 | {"concat", {LUA_T_CFUNCTION, {concatFB}}}, | 36 | {"concat", {LUA_T_CFUNCTION, {concatFB}}, 2, 1}, |
| 37 | {"settable", {LUA_T_CFUNCTION, {gettableFB}}}, | 37 | {"settable", {LUA_T_CFUNCTION, {gettableFB}}, 3, 0}, |
| 38 | {"gc", {LUA_T_CFUNCTION, {GDFB}}}, | 38 | {"gc", {LUA_T_CFUNCTION, {GDFB}}, 1, 0}, |
| 39 | {"function", {LUA_T_CFUNCTION, {funcFB}}} | 39 | {"function", {LUA_T_CFUNCTION, {funcFB}}, -1, -1} |
| 40 | /* no fixed number of params or results */ | ||
| 40 | }; | 41 | }; |
| 41 | 42 | ||
| 42 | #define N_FB (sizeof(luaI_fallBacks)/sizeof(struct FB)) | 43 | #define N_FB (sizeof(luaI_fallBacks)/sizeof(struct FB)) |
