|
3217 | 3217 | %eval_40(=,_RetType,_,_,['make-var'|Types],Var):- !, 'mx__1_0+_make-var'(Types,Var). |
3218 | 3218 | %eval_40(=,_RetType,_,_,['bless-var',Var|Types],Var):- !, 'mx__1_1+_bless-var'(Var,Types,Var). |
3219 | 3219 |
|
3220 | | -transpiler_peek(Sym,Len,Type,Fn, N):- |
3221 | | - transpiler_predicate_store(_Builtin, Sym, [Len], _, _, _, _), |
| 3220 | +transpiler_peek(Sym,Len,Type,Fn, Min):- |
| 3221 | + transpiler_predicate_nary_store(_Builtin, Sym, Min, _, _, _, _, _, _), |
| 3222 | + Len>=Min,between(0,Len,N), |
3222 | 3223 | if_t(var(Type),member(Type,['mx','mi','mc'])), |
3223 | | - between(0,Len,N),succ(N,N1), |
3224 | 3224 | format(atom(Fn),'~w__1_~w+_~w',[Type,N,Sym]), |
3225 | | - succ(N1,LenP1), current_predicate(Fn/LenP1), |
| 3225 | + succ(N,N1),succ(N1,LenP1), current_predicate(Fn/LenP1), |
3226 | 3226 | %\+ transpiler_predicate_store(_,Sym,[_],_,_,_,_), |
3227 | 3227 | ignore(ok_call_predicate(Sym,Len,Type)). |
3228 | 3228 |
|
|
3265 | 3265 | with_metta_ctx(_Eq,_RetType,_Depth,_Self,_MeTTaSrc,Goal):- Goal. |
3266 | 3266 |
|
3267 | 3267 | :- dynamic memoized_result/3. |
3268 | | -memoize_tf(Goal) :- |
| 3268 | +memoize_tf(Goal) :- call(Goal). |
| 3269 | +memoize_tf_real(Goal) :- |
3269 | 3270 | term_variables(Goal, Vars), |
3270 | 3271 | copy_term(Goal, CopyGoal),numbervars(CopyGoal,0,_,[attvar(bind)]), |
3271 | 3272 | ( memoized_result(CopyGoal, Vars, Result) -> |
|
0 commit comments