diff options
Diffstat (limited to 'src/interp/wi2.boot')
-rw-r--r-- | src/interp/wi2.boot | 55 |
1 files changed, 0 insertions, 55 deletions
diff --git a/src/interp/wi2.boot b/src/interp/wi2.boot index c66763cf..31983811 100644 --- a/src/interp/wi2.boot +++ b/src/interp/wi2.boot @@ -408,61 +408,6 @@ macroExpand(x,e) == --not worked out yet ['MI,a,macroExpand(b,e)] macroExpandList(x,e) -getSuccessEnvironment(a,e) == - -- the next four lines try to ensure that explicit special-case tests - -- prevent implicit ones from being generated - a is ["has",x,m] => - x := unLet x - IDENTP x and isDomainForm(m,$EmptyEnvironment) => put(x,"specialCase",m,e) - e - a is ["is",id,m] => - id := unLet id - IDENTP id and isDomainForm(m,$EmptyEnvironment) => - e:=put(id,"specialCase",m,e) - currentProplist:= getProplist(id,e) - [.,.,e] := T := comp(m,$EmptyMode,e) or return nil -- duplicates compIs - newProplist:= consProplistOf(id,currentProplist,"value",removeEnv T) - addBinding(id,newProplist,e) - e - a is ["case",x,m] and (x := unLet x) and IDENTP x => - put(x,"condition",[a,:get(x,"condition",e)],e) - e - -getInverseEnvironment(a,E) == - atom a => E - [op,:argl]:= a --- the next five lines try to ensure that explicit special-case tests --- prevent implicit ones from being generated - op="has" => - [x,m]:= argl - x := unLet x - IDENTP x and isDomainForm(m,$EmptyEnvironment) => put(x,"specialCase",m,E) - E - a is ["case",x,m] and (x := unLet x) and IDENTP x => - --the next two lines are necessary to get 3-branched Unions to work - -- old-style unions, that is - if corrupted? get(x,"condition",E) then systemError 'condition - (get(x,"condition",E) is [["OR",:oldpred]]) and member(a,oldpred) => - put(x,"condition",LIST MKPF(delete(a,oldpred),"OR"),E) - getUnionMode(x,E) is ["Union",:l] or systemError 'Union - if corrupted? l then systemError 'list - l':= delete(m,l) - for u in l' repeat - if u is ['_:,=m,:.] then l':= delete(u,l') - newpred:= MKPF([["case",x,m'] for m' in l'],"OR") - put(x,"condition",[newpred,:get(x,"condition",E)],E) - E - -unLet x == - x is ["%LET",u,:.] => unLet u - x - -corrupted? u == - u is [op,:r] => - op in '(WI MI PART) => true - or/[corrupted? x for x in r] - false - --====================================================================== -- From apply.boot --====================================================================== |