add SWI compatible file_name_variables flag.
This commit is contained in:
parent
e1fdbd7537
commit
249010bd90
@ -1079,7 +1079,6 @@ initPrologFlags(void)
|
||||
ALLOW_VARNAME_FUNCTOR);
|
||||
setPrologFlag("toplevel_var_size", FT_INTEGER, 1000);
|
||||
setPrologFlag("toplevel_print_anon", FT_BOOL, TRUE, 0);
|
||||
setPrologFlag("file_name_variables", FT_BOOL, FALSE, PLFLAG_FILEVARS);
|
||||
#ifdef __unix__
|
||||
setPrologFlag("unix", FT_BOOL|FF_READONLY, TRUE, 0);
|
||||
#endif
|
||||
@ -1105,6 +1104,7 @@ initPrologFlags(void)
|
||||
setPrologFlag("tty_control", FT_BOOL|FF_READONLY,
|
||||
truePrologFlag(PLFLAG_TTY_CONTROL), PLFLAG_TTY_CONTROL);
|
||||
setPrologFlag("encoding", FT_ATOM, stringAtom(encoding_to_atom(LD->encoding)));
|
||||
setPrologFlag("file_name_variables", FT_BOOL, FALSE, PLFLAG_FILEVARS);
|
||||
setPrologFlag("fileerrors", FT_BOOL, TRUE, PLFLAG_FILEERRORS);
|
||||
setPrologFlag("readline", FT_BOOL/*|FF_READONLY*/, FALSE, 0);
|
||||
|
||||
|
10
pl/flags.yap
10
pl/flags.yap
@ -60,7 +60,14 @@ yap_flag(encoding,X) :-
|
||||
yap_flag(encoding,X) :-
|
||||
'$swi_set_prolog_flag'(encoding, X).
|
||||
|
||||
% character encoding...
|
||||
% file_name_variables...
|
||||
yap_flag(file_name_variables,X) :-
|
||||
var(X), !,
|
||||
'$swi_current_prolog_flag'(file_name_variables, X).
|
||||
yap_flag(file_name_variables,X) :-
|
||||
'$swi_set_prolog_flag'(file_name_variables, X).
|
||||
|
||||
% fileerrors...
|
||||
yap_flag(fileerrors,X) :-
|
||||
var(X), !,
|
||||
'$swi_current_prolog_flag'(fileerrors, X).
|
||||
@ -813,6 +820,7 @@ yap_flag(dialect,yap).
|
||||
'$yap_system_flag'(encoding).
|
||||
'$yap_system_flag'(executable).
|
||||
% V = fast ;
|
||||
'$yap_system_flag'(file_name_variables).
|
||||
'$yap_system_flag'(fileerrors ).
|
||||
'$yap_system_flag'(float_format).
|
||||
% V = float_mantissa_digits ;
|
||||
|
Reference in New Issue
Block a user