allow multifile as an user predicate.

This commit is contained in:
Vitor Santos Costa 2011-06-14 09:02:16 +01:00
parent 49450cbbf4
commit eaf96e918b

View File

@ -256,6 +256,10 @@ no_style_check([H|T]) :- no_style_check(H), no_style_check(T).
'$multiple_has_been_defined'(Fil,P,M) :-
print_message(warning,defined_elsewhere(M:P,Fil)).
multifile(P) :-
'$current_module'(OM),
'$multifile'(P, M).
'$multifile'(V, _) :- var(V), !,
'$do_error'(instantiation_error,multifile(V)).
'$multifile'((X,Y), M) :- !, '$multifile'(X, M), '$multifile'(Y, M).