fix different semantics for yapor.
This commit is contained in:
parent
f59f8e3f1a
commit
b2c1523de6
@ -187,9 +187,9 @@ ensure_loaded(Fs) :-
|
|||||||
compile(Fs) :-
|
compile(Fs) :-
|
||||||
'$load_files'(Fs, [], compile(Fs)).
|
'$load_files'(Fs, [], compile(Fs)).
|
||||||
|
|
||||||
consult(Fs) :-
|
% consult(Fs) :-
|
||||||
'$has_yap_or',
|
% '$has_yap_or',
|
||||||
'$do_error'(context_error(consult(Fs),clause),query).
|
% '$do_error'(context_error(consult(Fs),clause),query).
|
||||||
consult(V) :-
|
consult(V) :-
|
||||||
var(V), !,
|
var(V), !,
|
||||||
'$do_error'(instantiation_error,consult(V)).
|
'$do_error'(instantiation_error,consult(V)).
|
||||||
|
@ -651,10 +651,10 @@ abolish(X) :-
|
|||||||
print_message(warning,no_match(abolish(Module:Name/Arity))).
|
print_message(warning,no_match(abolish(Module:Name/Arity))).
|
||||||
% I cannot allow modifying static procedures in YAPOR
|
% I cannot allow modifying static procedures in YAPOR
|
||||||
% this code has to be here because of abolish/2
|
% this code has to be here because of abolish/2
|
||||||
'$abolishs'(G, Module) :-
|
% '$abolishs'(G, Module) :-
|
||||||
'$has_yap_or', !,
|
% '$has_yap_or', !,
|
||||||
functor(G,A,N),
|
% functor(G,A,N),
|
||||||
'$do_error'(permission_error(modify,static_procedure,A/N),abolish(Module:G)).
|
% '$do_error'(permission_error(modify,static_procedure,A/N),abolish(Module:G)).
|
||||||
'$abolishs'(G, M) :-
|
'$abolishs'(G, M) :-
|
||||||
'$is_multifile'(G,M), !,
|
'$is_multifile'(G,M), !,
|
||||||
functor(G,Name,Arity),
|
functor(G,Name,Arity),
|
||||||
|
Reference in New Issue
Block a user