diff --git a/C/c_interface.c b/C/c_interface.c index 9152df9c2..34fd93543 100644 --- a/C/c_interface.c +++ b/C/c_interface.c @@ -10,8 +10,11 @@ * File: c_interface.c * * comments: c_interface primitives definition * * * -* Last rev: $Date: 2008-02-12 17:03:50 $,$Author: vsc $ * +* Last rev: $Date: 2008-03-13 18:41:50 $,$Author: vsc $ * * $Log: not supported by cvs2svn $ +* Revision 1.106 2008/02/12 17:03:50 vsc +* SWI-portability changes +* * Revision 1.105 2008/01/28 10:42:19 vsc * fix BOM trouble * @@ -1681,6 +1684,9 @@ YAP_Init(YAP_init_args *yap_init) yap_init->DelayedReleaseLoad ); Yap_InitExStacks (Trail, Stack); + if (yap_init->QuietMode) { + yap_flags[QUIET_MODE_FLAG] = TRUE; + } { BACKUP_MACHINE_REGS(); Yap_InitYaamRegs(); @@ -1773,6 +1779,9 @@ YAP_Init(YAP_init_args *yap_init) if (yap_init->YapPrologAddPath) { Yap_PutValue(Yap_FullLookupAtom("$extend_file_search_path"), MkAtomTerm(Yap_LookupAtom(yap_init->YapPrologAddPath))); } + if (yap_init->QuietMode) { + yap_flags[QUIET_MODE_FLAG] = TRUE; + } if (yap_init->SavedState != NULL || yap_init->YapPrologBootFile == NULL) { if (restore_result == FAIL_RESTORE) { @@ -1816,6 +1825,7 @@ YAP_FastInit(char saved_state[]) init_args.Argv = NULL; init_args.ErrorNo = 0; init_args.ErrorCause = NULL; + init_args.QuietMode = FALSE; out = YAP_Init(&init_args); if (out == YAP_BOOT_FROM_SAVED_ERROR) { Yap_Error(init_args.ErrorNo,TermNil,init_args.ErrorCause); diff --git a/C/init.c b/C/init.c index 838bdf3be..58fc565b7 100644 --- a/C/init.c +++ b/C/init.c @@ -859,6 +859,7 @@ InitFlags(void) /* current default */ yap_flags[INDEXING_MODE_FLAG] = INDEX_MODE_MULTI; yap_flags[TABLING_MODE_FLAG] = 0; + yap_flags[QUIET_MODE_FLAG] = FALSE; } static void diff --git a/C/save.c b/C/save.c index 2790f0e89..998c9d1e7 100644 --- a/C/save.c +++ b/C/save.c @@ -1398,7 +1398,7 @@ commit_to_saved_state(char *s, CELL *Astate, CELL *ATrail, CELL *AStack, CELL *A return(FAIL_RESTORE); Yap_PrologMode = BootMode; if (Yap_HeapBase) { - if (!yap_flags[HALT_AFTER_CONSULT_FLAG]) { + if (!yap_flags[HALT_AFTER_CONSULT_FLAG] && !yap_flags[QUIET_MODE_FLAG]) { Yap_TrueFileName(s,Yap_FileNameBuf2, YAP_FILENAME_MAX); fprintf(stderr, "%% Restoring file %s\n", Yap_FileNameBuf2); } diff --git a/H/Yap.h b/H/Yap.h index 4ead7b25c..8fb19e8c9 100644 --- a/H/Yap.h +++ b/H/Yap.h @@ -10,7 +10,7 @@ * File: Yap.h.m4 * * mods: * * comments: main header file for YAP * -* version: $Id: Yap.h,v 1.27 2008-02-12 21:50:58 vsc Exp $ * +* version: $Id: Yap.h,v 1.28 2008-03-13 18:41:50 vsc Exp $ * *************************************************************************/ #include "config.h" @@ -521,8 +521,9 @@ typedef enum INDEXING_MODE_FLAG = 19, TABLING_MODE_FLAG = 20, VARS_CAN_HAVE_QUOTE_FLAG = 21, + QUIET_MODE_FLAG = 22, /* let this be the last one */ - LAST_FLAG = 22 + LAST_FLAG = 23 } yap_flags; #define STRING_AS_CHARS 0 diff --git a/changes-5.1.html b/changes-5.1.html index e9d159648..4eeab30ee 100644 --- a/changes-5.1.html +++ b/changes-5.1.html @@ -17,6 +17,10 @@ xb

Yap-5.1.3: