aboutsummaryrefslogtreecommitdiff
path: root/fallback.h
diff options
context:
space:
mode:
Diffstat (limited to 'fallback.h')
-rw-r--r--fallback.h60
1 files changed, 43 insertions, 17 deletions
diff --git a/fallback.h b/fallback.h
index e34363af..ea071191 100644
--- a/fallback.h
+++ b/fallback.h
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: fallback.h,v 1.14 1997/02/26 17:38:41 roberto Unstable roberto $ 2** $Id: fallback.h,v 1.15 1997/03/19 19:41:10 roberto Exp roberto $
3*/ 3*/
4 4
5#ifndef fallback_h 5#ifndef fallback_h
@@ -8,19 +8,44 @@
8#include "lua.h" 8#include "lua.h"
9#include "opcode.h" 9#include "opcode.h"
10 10
11#define IM_GETTABLE 0 11/*
12#define IM_ARITH 1 12* WARNING: if you change the order of this enumeration,
13#define IM_ORDER 2 13* grep "ORDER IM"
14#define IM_CONCAT 3 14*/
15#define IM_SETTABLE 4 15typedef enum {
16#define IM_GC 5 16 IM_GETTABLE = 0,
17#define IM_FUNCTION 6 17 IM_SETTABLE,
18#define IM_INDEX 7 18 IM_INDEX,
19#define IM_N 8 19 IM_ADD,
20 20 IM_SUB,
21#define GIM_ERROR 0 21 IM_MUL,
22#define GIM_GETGLOBAL 1 22 IM_DIV,
23#define GIM_SETGLOBAL 2 23 IM_POW,
24 IM_UNM,
25 IM_LT,
26 IM_LE,
27 IM_GT,
28 IM_GE,
29 IM_CONCAT,
30 IM_GC,
31 IM_FUNCTION
32} IMS;
33
34#define IM_N 16
35
36extern char *luaI_eventname[];
37
38
39/*
40* WARNING: if you change the order of this enumeration,
41* grep "ORDER GIM"
42*/
43typedef enum {
44 GIM_ERROR = 0,
45 GIM_GETGLOBAL,
46 GIM_SETGLOBAL
47} IMGS;
48
24#define GIM_N 3 49#define GIM_N 3
25 50
26void luaI_setfallback (void); 51void luaI_setfallback (void);
@@ -30,11 +55,12 @@ void luaI_travlock (int (*fn)(Object *));
30void luaI_invalidaterefs (void); 55void luaI_invalidaterefs (void);
31char *luaI_travfallbacks (int (*fn)(Object *)); 56char *luaI_travfallbacks (int (*fn)(Object *));
32 57
58void luaI_type (void);
33void luaI_settag (int tag, Object *o); 59void luaI_settag (int tag, Object *o);
34lua_Type luaI_typetag (int tag); 60lua_Type luaI_typetag (int tag);
35Object *luaI_getim (int tag, int event); 61Object *luaI_getim (int tag, IMS event);
36Object *luaI_getgim (int event); 62Object *luaI_getgim (IMGS event);
37Object *luaI_getimbyObj (Object *o, int event); 63Object *luaI_getimbyObj (Object *o, IMS event);
38int luaI_tag (Object *o); 64int luaI_tag (Object *o);
39void luaI_setintmethod (void); 65void luaI_setintmethod (void);
40void luaI_setglobalmethod (void); 66void luaI_setglobalmethod (void);