initialization predicates should execute in consulted module.

git-svn-id: https://yap.svn.sf.net/svnroot/yap/trunk@692 b08c6af1-5177-4d33-ba66-4b1c6b8b522a
This commit is contained in:
vsc 2002-11-19 14:43:17 +00:00
parent d7f80ea1ad
commit 35f1d9cf63
2 changed files with 13 additions and 13 deletions

View File

@ -926,9 +926,13 @@ break :- '$get_value'('$break',BL), NBL is BL+1,
'$print_message'(informational, loading(consulting, File))
),
'$loop'(Stream,consult),
'$current_module'(Mod,OldModule),
'$end_consult',
'$cd'(OldD),
'$set_value'('$consulting',Old),
'$set_value'('$consulting_file',OldF),
( LC == 0 -> prompt(_,' |: ') ; true),
'$exec_initialisation_goals',
'$current_module'(Mod,OldModule),
H is heapused-H0, '$cputime'(TF,_), T is TF-T0,
( '$undefined'('$print_message'(_,_),prolog) ->
( '$get_value'('$verbose',on) ->
@ -939,10 +943,6 @@ break :- '$get_value'('$break',BL), NBL is BL+1,
;
'$print_message'(informational, loaded(consulted, File, Mod, T, H))
),
'$set_value'('$consulting',Old),
'$set_value'('$consulting_file',OldF),
'$cd'(OldD),
'$exec_initialisation_goals',
!.

View File

@ -111,16 +111,16 @@ reconsult(Fs) :-
'$recorda'('$initialisation','$',_),
'$print_message'(informational, loading(reconsulting, File)),
'$loop'(Stream,reconsult),
'$current_module'(Mod,OldModule),
'$end_consult',
'$clear_reconsulting',
( LC == 0 -> prompt(_,' |: ') ; true),
H is heapused-H0, '$cputime'(TF,_), T is TF-T0,
'$print_message'(informational, loaded(reconsulted, File, Mod, T, H)),
'$set_value'('$consulting',Old),
'$set_value'('$consulting_file',OldF),
'$cd'(OldD),
'$exec_initialisation_goals',
'$current_module'(Mod,OldModule),
( LC == 0 -> prompt(_,' |: ') ; true),
H is heapused-H0, '$cputime'(TF,_), T is TF-T0,
'$print_message'(informational, loaded(reconsulted, File, Mod, T, H)),
!.
'$start_reconsulting'(F) :-
@ -144,16 +144,16 @@ reconsult(Fs) :-
'$recorda'('$initialisation','$',_),
'$print_message'(informational, loading(reconsulting, File)),
'$loop'(Stream,reconsult),
'$current_module'(Mod,OldModule),
'$end_consult',
'$clear_reconsulting',
( LC == 0 -> prompt(_,' |: ') ; true),
H is heapused-H0, '$cputime'(TF,_), T is TF-T0,
'$print_message'(informational, loaded(reconsulted, File, Mod, T, H)),
'$set_value'('$consulting',Old),
'$set_value'('$consulting_file',OldF),
'$cd'(OldD),
'$exec_initialisation_goals',
'$current_module'(Mod,OldModule),
( LC == 0 -> prompt(_,' |: ') ; true),
H is heapused-H0, '$cputime'(TF,_), T is TF-T0,
'$print_message'(informational, loaded(reconsulted, File, Mod, T, H)),
!.