diff options
author | dos-reis <gdr@axiomatics.org> | 2010-06-04 18:26:33 +0000 |
---|---|---|
committer | dos-reis <gdr@axiomatics.org> | 2010-06-04 18:26:33 +0000 |
commit | bd67b8d8c796161376a6268c54f4d10fb0412e07 (patch) | |
tree | 8c60ab486096a0c62d2823e44b7f69e1680cdd27 | |
parent | 69ad281c414918448007110d80e0e2971cfde6e4 (diff) | |
download | open-axiom-bd67b8d8c796161376a6268c54f4d10fb0412e07.tar.gz |
* interp/buildom.boot (UnionEqual): Don't COERCE to FUNCTION. Use
eval.
(coerceUn2E): Likewise.
-rw-r--r-- | src/ChangeLog | 6 | ||||
-rw-r--r-- | src/interp/buildom.boot | 4 | ||||
-rw-r--r-- | src/interp/g-util.boot | 3 |
3 files changed, 10 insertions, 3 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index 0334cd71..f2c96f40 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,9 @@ +2010-06-04 Gabriel Dos Reis <gdr@cs.tamu.edu> + + * interp/buildom.boot (UnionEqual): Don't COERCE to FUNCTION. Use + eval. + (coerceUn2E): Likewise. + 2010-06-03 Gabriel Dos Reis <gdr@cs.tamu.edu> * interp/br-con.boot: More cleanup. diff --git a/src/interp/buildom.boot b/src/interp/buildom.boot index b76c110a..c242faf2 100644 --- a/src/interp/buildom.boot +++ b/src/interp/buildom.boot @@ -183,7 +183,7 @@ UnionEqual(x, y, dom) == predlist := mkPredList branches same := false for b in stripUnionTags branches for p in predlist while not same repeat - typeFun := COERCE(["LAMBDA", '(_#1), p],"FUNCTION") + typeFun := eval ['%lam,'(_#1),p] FUNCALL(typeFun,x) and FUNCALL(typeFun,y) => string? b => same := (x = y) if p is ["EQCAR", :.] then (x := rest x; y := rest y) @@ -197,7 +197,7 @@ coerceUn2E(x,source) == predlist := mkPredList branches byGeorge := byJane := gensym() for b in stripUnionTags branches for p in predlist repeat - typeFun := COERCE(["LAMBDA", '(_#1), p],"FUNCTION") + typeFun := eval ['%lam,'(_#1),p] if FUNCALL(typeFun,x) then return if p is ["EQCAR", :.] then x := rest x -- string? b => return x -- to catch "failed" etc. diff --git a/src/interp/g-util.boot b/src/interp/g-util.boot index 05abd896..957d676a 100644 --- a/src/interp/g-util.boot +++ b/src/interp/g-util.boot @@ -322,7 +322,8 @@ for x in [ ['%string?, :'STRINGP], -- general utility - ['%hash,:'SXHASH] + ['%hash,:'SXHASH], + ['%lam, :'LAMBDA] ] repeat property(first x,'%Rename) := rest x ++ Table of opcode-expander pairs. |