hedgewars/LuaPas.pas
changeset 7151 ec15d9e1a7e3
parent 7073 26f960656cc9
child 8026 4a4f21070479
child 8838 aa2ffd427f6a
--- a/hedgewars/LuaPas.pas	Wed May 30 19:01:19 2012 +0400
+++ b/hedgewars/LuaPas.pas	Thu May 31 15:14:39 2012 +0400
@@ -1,4 +1,5 @@
 {$HINTS OFF}
+{$INCLUDE "options.inc"}
 
 unit LuaPas;
 
@@ -23,8 +24,7 @@
     lua_State = record end;
     Plua_State = ^lua_State;
 
-const
-    LuaLibName = cLuaLibrary;
+{$DEFINE LuaLibName:= cLuaLibrary}
 
 
 (*****************************************************************************)
@@ -81,8 +81,8 @@
 ** CHANGE them if you want to improve this functionality (e.g., by using
 ** GNU readline and history facilities).
 *)
-function  lua_readline(L : Plua_State;
-var b : PChar; p : PChar): Boolean;
+{function  lua_readline(L : Plua_State;
+var b : PChar; p : PChar): Boolean;}
 
 procedure lua_saveline(L : Plua_State; idx : LongInt);
 
@@ -119,7 +119,7 @@
     LUA_AUTHORS     = 'R. Ierusalimschy, L. H. de Figueiredo & W. Celes';
 
     (* mark for precompiled code (`<esc>Lua') *)
-    LUA_SIGNATURE = #27 + 'Lua';
+    //LUA_SIGNATURE = #27'Lua';
 
     (* option for multiple returns in `lua_pcall' and `lua_call' *)
     LUA_MULTRET = -1;
@@ -799,7 +799,7 @@
 (*****************************************************************************)
 (*                            luaconfig.h                                    *)
 (*****************************************************************************)
-
+{
 function  lua_readline(L : Plua_State;
 var
     b : PChar; p : PChar): Boolean;
@@ -811,7 +811,7 @@
     b := PChar(s);                   //   and return it
     lua_readline := (b[0] <> #4);          // test for ctrl-D
 end;
-
+}
 procedure lua_saveline(L : Plua_State; idx : LongInt);
 begin
 end;
@@ -1041,7 +1041,7 @@
         lua_ref := luaL_ref(L, LUA_REGISTRYINDEX)
     else
         begin
-        lua_pushstring(L, 'unlocked references are obsolete');
+        lua_pushstring(L, _P'unlocked references are obsolete');
         lua_error(L);
         lua_ref := 0;
         end;