From 609392ff2e02eb44fa48c8563faf5994fc55297c Mon Sep 17 00:00:00 2001 From: Roberto Ierusalimschy Date: Mon, 21 Nov 1994 16:22:58 -0200 Subject: fallback for "call expression not a function" errors --- fallback.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'fallback.c') diff --git a/fallback.c b/fallback.c index a41712cc..0076da24 100644 --- a/fallback.c +++ b/fallback.c @@ -3,7 +3,7 @@ ** TecCGraf - PUC-Rio */ -char *rcs_fallback="$Id: fallback.c,v 1.7 1994/11/18 19:46:21 roberto Exp roberto $"; +char *rcs_fallback="$Id: fallback.c,v 1.8 1994/11/21 13:30:15 roberto Exp roberto $"; #include @@ -21,6 +21,7 @@ static void arithFB (void); static void concatFB (void); static void orderFB (void); static void GDFB (void); +static void funcFB (void); /* @@ -34,7 +35,8 @@ struct FB luaI_fallBacks[] = { {"order", {LUA_T_CFUNCTION, orderFB}}, {"concat", {LUA_T_CFUNCTION, concatFB}}, {"settable", {LUA_T_CFUNCTION, gettableFB}}, -{"gc", {LUA_T_CFUNCTION, GDFB}} +{"gc", {LUA_T_CFUNCTION, GDFB}}, +{"function", {LUA_T_CFUNCTION, funcFB}} }; #define N_FB (sizeof(luaI_fallBacks)/sizeof(struct FB)) @@ -103,6 +105,11 @@ static void orderFB (void) static void GDFB (void) { } +static void funcFB (void) +{ + lua_reportbug("call expression not a function"); +} + /* ** Lock routines -- cgit v1.2.3-55-g6feb