meta-calls
moduls vs python
This commit is contained in:
parent
eee6760f96
commit
0b742f3ae3
6
C/exec.c
6
C/exec.c
@ -440,10 +440,10 @@ restart_exec:
|
|||||||
pen = RepPredProp(PredPropByFunc(f, mod));
|
pen = RepPredProp(PredPropByFunc(f, mod));
|
||||||
/* You thought we would be over by now */
|
/* You thought we would be over by now */
|
||||||
/* but no meta calls require special preprocessing */
|
/* but no meta calls require special preprocessing */
|
||||||
if (pen->PredFlags & (MetaPredFlag | UndefPredFlag)) {
|
// if (pen->PredFlags & (MetaPredFlag | UndefPredFlag)) {
|
||||||
// Term t = copy_execn_to_heap(f, pt, n, arity, mod PASS_REGS);
|
// Term t = copy_execn_to_heap(f, pt, n, arity, mod PASS_REGS);
|
||||||
return (CallMetaCall(t0, mod0 PASS_REGS));
|
//return (CallMetaCall(t0, mod0 PASS_REGS));
|
||||||
}
|
//}
|
||||||
/* now let us do what we wanted to do from the beginning !! */
|
/* now let us do what we wanted to do from the beginning !! */
|
||||||
/* I cannot use the standard macro here because
|
/* I cannot use the standard macro here because
|
||||||
otherwise I would dereference the argument and
|
otherwise I would dereference the argument and
|
||||||
|
@ -1414,7 +1414,6 @@ initialization(_G,_OPT).
|
|||||||
OPT, initialization(G0,OPT)),
|
OPT, initialization(G0,OPT)),
|
||||||
'$yap_strip_module'(G0,M,G1),
|
'$yap_strip_module'(G0,M,G1),
|
||||||
'$expand_term'((M:G1), G),
|
'$expand_term'((M:G1), G),
|
||||||
writeln(G),
|
|
||||||
(
|
(
|
||||||
OPT == now
|
OPT == now
|
||||||
->
|
->
|
||||||
|
@ -306,6 +306,10 @@ meta_predicate declaration
|
|||||||
('$current_choice_point'(CP),AO,'$$cut_by'(CP)),HM,SM,BM,HVars) :- !,
|
('$current_choice_point'(CP),AO,'$$cut_by'(CP)),HM,SM,BM,HVars) :- !,
|
||||||
'$expand_goals'(A,A1,AO0,HM,SM,BM,HVars),
|
'$expand_goals'(A,A1,AO0,HM,SM,BM,HVars),
|
||||||
'$clean_cuts'(AO0, CP, AO).
|
'$clean_cuts'(AO0, CP, AO).
|
||||||
|
'$expand_goals'((:-A),(:-A1),
|
||||||
|
(:-AO),HM,SM,BM,HVars) :- !,
|
||||||
|
'$expand_goals'(A,A1,AO0,HM,SM,BM,HVars),
|
||||||
|
'$clean_cuts'(AO0, CP, AO).
|
||||||
'$expand_goals'(ignore(A),ignore(A1),
|
'$expand_goals'(ignore(A),ignore(A1),
|
||||||
('$current_choice_point'(CP),AO,'$$cut_by'(CP)-> true ; true),HM,SM,BM,HVars) :- !,
|
('$current_choice_point'(CP),AO,'$$cut_by'(CP)-> true ; true),HM,SM,BM,HVars) :- !,
|
||||||
'$expand_goals'(A,A1,AO0,HM,SM,BM,HVars),
|
'$expand_goals'(A,A1,AO0,HM,SM,BM,HVars),
|
||||||
|
Reference in New Issue
Block a user