more fixes to SWI emulation

integrate in main binary
This commit is contained in:
Vitor Santos Costa
2011-02-10 21:14:38 +00:00
parent 841f6eb1e5
commit 3fe9b923cb
12 changed files with 462 additions and 64 deletions

View File

@@ -1,6 +1,10 @@
#include "config.h"
#if USE_GMP
#define O_GMP 1
#endif
#define PL_KERNEL 1
#ifdef __MINGW32__
@@ -218,6 +222,28 @@ typedef struct
} nv_options;
/*******************************
* GET-PROCEDURE *
*******************************/
#define GP_FIND 0 /* find anywhere */
#define GP_FINDHERE 1 /* find in this module */
#define GP_CREATE 2 /* create (in this module) */
#define GP_DEFINE 4 /* define a procedure */
#define GP_RESOLVE 5 /* find defenition */
#define GP_HOW_MASK 0x0ff
#define GP_NAMEARITY 0x100 /* or'ed mask */
#define GP_HIDESYSTEM 0x200 /* hide system module */
#define GP_TYPE_QUIET 0x400 /* don't throw errors on wrong types */
#define GP_EXISTENCE_ERROR 0x800 /* throw error if proc is not found */
#define GP_QUALIFY 0x1000 /* Always module-qualify */
/* get_functor() */
#define GF_EXISTING 1
#define GF_PROCEDURE 2 /* check for max arity */
/*******************************
* LIST BUILDING *
*******************************/
@@ -603,6 +629,13 @@ typedef struct PL_local_data {
int _current_buffer_id;
} fli;
#ifdef O_GMP
struct
{
int persistent; /* do persistent operations */
} gmp;
#endif
} PL_local_data_t;
#define usedStack(D) 0
@@ -1060,3 +1093,9 @@ setInteger(int *flag, term_t old, term_t new)
succeed;
}
extern const PL_extension PL_predicates_from_ctype[];
extern const PL_extension PL_predicates_from_file[];
extern const PL_extension PL_predicates_from_files[];
extern const PL_extension PL_predicates_from_glob[];
extern const PL_extension PL_predicates_from_write[];