aboutsummaryrefslogtreecommitdiff
path: root/src/interp/compiler.boot
diff options
context:
space:
mode:
authordos-reis <gdr@axiomatics.org>2011-08-25 19:23:54 +0000
committerdos-reis <gdr@axiomatics.org>2011-08-25 19:23:54 +0000
commit635d8e32c29f94a2e4813e36a75bdfba167e8ac1 (patch)
tree48d7673e043a60f0e6d949924b6f4a8cf7cfd7d9 /src/interp/compiler.boot
parentcd5a921db34f465d1dc8fbd2061d9077f64434cf (diff)
downloadopen-axiom-635d8e32c29f94a2e4813e36a75bdfba167e8ac1.tar.gz
* interp/compiler.boot (compHasFormat): Take environment
argument. Adjust callers. * interp/define.boot (NRTmakeCategoryAlist): Likewise. * interp/functor.boot (ProcessCond): Likewise. * interp/lisplib.boot (NRTgenFinalAttributeAlist): Likewise. (predicateBitIndex): Likewise. (predicateBitRef): Likewise. (makePredicateBitVector): Likewise. (transHasCode): Likewise.
Diffstat (limited to 'src/interp/compiler.boot')
-rw-r--r--src/interp/compiler.boot16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/interp/compiler.boot b/src/interp/compiler.boot
index 3e828bba..49aa460a 100644
--- a/src/interp/compiler.boot
+++ b/src/interp/compiler.boot
@@ -1231,26 +1231,26 @@ compElt(form,m,E) ==
--% HAS
compHas: (%Form,%Mode,%Env) -> %Maybe %Triple
-compHas(pred is ["has",a,b],m,$e) ==
- $e:= chaseInferences(pred,$e)
- predCode:= compHasFormat pred
- coerce([predCode,$Boolean,$e],m)
+compHas(pred is ["has",a,b],m,e) ==
+ e := chaseInferences(pred,e)
+ predCode := compHasFormat(pred,e)
+ coerce([predCode,$Boolean,e],m)
--used in various other places to make the discrimination
-compHasFormat (pred is ["has",olda,b]) ==
+compHasFormat(pred is ["has",olda,b],e) ==
argl := rest $form
formals := TAKE(#argl,$FormalMapVariableList)
a := applySubst(pairList(formals,argl),olda)
- [a,:.] := comp(a,$EmptyMode,$e) or return nil
+ [a,.,e] := comp(a,$EmptyMode,e) or return nil
a := applySubst(pairList(argl,formals),a)
b is ["ATTRIBUTE",c] => ["HasAttribute",a,["QUOTE",c]]
b is ["SIGNATURE",op,sig,:.] =>
["HasSignature",a,
mkList [MKQ op,mkList [mkTypeForm type for type in sig]]]
b is ["Join",:l] or b is ["CATEGORY",.,:l] =>
- ["AND",:[compHasFormat ["has",olda,c] for c in l]]
- isCategoryForm(b,$e) => ["HasCategory",a,mkTypeForm b]
+ ["AND",:[compHasFormat(["has",olda,c],e) for c in l]]
+ isCategoryForm(b,e) => ["HasCategory",a,mkTypeForm b]
stackAndThrow('"Second argument to %1b must be a category, or a signature or an attribute",["has"])
--% IF