accum-matching-tagged-indices(pre;st) ==
  let P = 
p.prefix-match(p;pre) in
   let tg = 
x.if pisend?(x) then pisend-val(x)
               if pisend?(pre) then pisend-val(pre)
               else []
               fi  in
   let indices = 
preList.select-tagged-indices(P;tg;preList) in
   let new_pair = 
loc,preList.<loc, indices preList> in
   let f = 
rslt,loc,preList.[new_pair loc preList / rslt] in
   fpf-accum(c,loc,preList.f c loc preList;[];st)
Definitions : 
prefix-match: prefix-match(p1;p2), 
ifthenelse: if b then t else f fi , 
pisend?: pisend?(x), 
pisend-val: pisend-val(x), 
select-tagged-indices: select-tagged-indices(P;tg;L), 
pair: <a, b>, 
let: let, 
lambda:
x.A[x], 
cons: [car / cdr], 
fpf-accum: fpf-accum(z,a,v.f[z; a; v];y;x), 
apply: f a, 
nil: []
FDL editor aliases : 
accum-matching-tagged-indices
accum-matching-tagged-indices(pre;st)  ==
    let  P  =  \mlambda{}p.prefix-match(p;pre)  in
      let  tg  =  \mlambda{}x.if  pisend?(x)  then  pisend-val(x)
                              if  pisend?(pre)  then  pisend-val(pre)
                              else  []
                              fi    in
      let  indices  =  \mlambda{}preList.select-tagged-indices(P;tg;preList)  in
      let  new$_{pair}$  =  \mlambda{}loc,preList.<loc,  indices  preList>  in
      let  f  =  \mlambda{}rslt,loc,preList.[new$_{pair}$  loc  preList  /  rslt]  in
      fpf-accum(c,loc,preList.f  c  loc  preList;[];st)
Date html generated:
2010_08_27-PM-08_45_52
Last ObjectModification:
2010_03_23-PM-06_22_35
Home
Index