indentation

This commit is contained in:
Vítor Santos Costa 2014-12-14 11:45:42 +00:00
parent 80363e359e
commit 15c79d8ecf
3 changed files with 45 additions and 31 deletions

View File

@ -362,7 +362,16 @@ true :- true.
(
'$undefined'('$init_preds',prolog)
->
get_value('$consult_on_boot',X),
(
X \= []
->
bootstrap(X),
module( user ),
qsave_program( "startup.yss")
;
true
)
;
'$init_state'
),
@ -457,8 +466,11 @@ true :- true.
)
), !.
'$handle_toplevel_error'(_, syntax_error(_)) :- !, fail.
'$handle_toplevel_error'(end_of_file, error(io_error(read,user_input),_)) :- !.
'$handle_toplevel_error'(_, syntax_error(_)) :-
!,
fail.
'$handle_toplevel_error'(end_of_file, error(io_error(read,user_input),_)) :-
!.
'$handle_toplevel_error'(_, E) :-
throw(E).
@ -490,7 +502,17 @@ true :- true.
set_value('$top_level_goal',[]),
'$run_atom_goal'(GA),
'$swi_current_prolog_flag'(break_level, BreakLevel),
( Breaklevel \= 0 -> true ; '$pred_exists'(halt(_), user) -> halt(0) ; '$halt'(0) ).
(
Breaklevel \= 0
->
true
;
'$pred_exists'(halt(_), user)
->
halt(0)
;
'$halt'(0)
).
'$enter_top_level' :-
flush_output,
'$run_toplevel_hooks',
@ -502,7 +524,16 @@ true :- true.
nb_setval('$debug_jump',off),
'$command'(Command,Varnames,_Pos,top),
'$swi_current_prolog_flag'(break_level, BreakLevel),
( BreakLevel \= 0 -> true ; '$pred_exists'(halt(_), user) -> halt(0) ; '$halt'(0) ).
(
BreakLevel \= 0
->
true
;
'$pred_exists'(halt(_), user)
-> halt(0)
;
'$halt'(0)
).
'$erase_sets' :-
@ -1299,21 +1330,6 @@ not(G) :- \+ '$execute'(G).
'$check_callable'(_,_).
'$silent_bootstrap'(F) :-
'$init_globals',
nb_setval('$if_level',0),
'$swi_current_prolog_flag'(verbose_load, OldSilent),
'$swi_set_prolog_flag'(verbose_load, silent),
bootstrap(F),
% -p option must be processed after initializing the system
'$swi_set_prolog_flag'(verbose_load, OldSilent).
bootstrap :-
'$argv'([F]),
bootstrap(F),
module(user),
qsave_program('startup.yss').
bootstrap(F) :-
% '$open'(F, '$csult', Stream, 0, 0, F),
% '$file_name'(Stream,File),

View File

@ -801,9 +801,7 @@ db_files(Fs) :-
lists:member(G,LGs),
% run initialization under user control (so allow debugging this stuff).
(
'$system_catch'(('$user_call'(G,M) -> true), M, Error, user:'$LoopError'(Error, top)),
fail
;
'$system_catch'('$user_call'(G,M), M, Error, user:'$LoopError'(Error, top)) ->
fail
).
'$exec_initialisation_goals' :-

View File

@ -118,7 +118,7 @@ otherwise.
:- bootstrap('os.yap').
:- bootstrap('absf.yap').
:-'$swi_set_prolog_flag'(verbose, normal).
:- [ 'directives.yap',
'utils.yap',