aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGabriel Dos Reis <gdr@axiomatics.org>2016-01-30 10:09:33 -0800
committerGabriel Dos Reis <gdr@axiomatics.org>2016-01-30 10:09:33 -0800
commit370affc3f817800a27946302f688d62dfe654877 (patch)
tree47ff13ea8af24b95e55854277820313cd98a7e36
parent18f925c1f6474349c4f808244c29cdf65fc0a70e (diff)
downloadopen-axiom-370affc3f817800a27946302f688d62dfe654877.tar.gz
Tidy category predicate conjunction.
-rw-r--r--src/interp/category.boot10
-rw-r--r--src/interp/sys-macros.lisp2
2 files changed, 5 insertions, 7 deletions
diff --git a/src/interp/category.boot b/src/interp/category.boot
index c5d4fbfe..ddba3a79 100644
--- a/src/interp/category.boot
+++ b/src/interp/category.boot
@@ -379,7 +379,7 @@ filterConditionalCategories(l,tbl,e) ==
listMember?(pred,get("$Information","special",e)) =>
--It's true, so we add it as unconditional
unconditionals := [CatEval(at,tbl,e),:unconditionals]
- pred isnt ["and",:.] =>
+ pred isnt ['and,:.] =>
conditionals := [[CatEval(at,tbl,e),pred],:conditionals]
-- Predicate is a conjunctive; decompose it.
pred' := [x for x in pred.args |
@@ -387,7 +387,7 @@ filterConditionalCategories(l,tbl,e) ==
and x isnt true]
pred' = nil => unconditionals := [CatEval(at,tbl,e),:unconditionals]
pred' is [x] => conditionals := [[CatEval(at,tbl,e),x],:conditionals]
- conditionals := [[CatEval(at,tbl,e),["and",:pred']],:conditionals]
+ conditionals := [[CatEval(at,tbl,e),mkpf(pred','and)],:conditionals]
[conditionals,reverse! unconditionals]
JoinInner(l,$e) ==
@@ -449,9 +449,7 @@ JoinInner(l,$e) ==
for u in categoryAttributes first b repeat
v := assoc(first u,attl)
null v =>
- attl :=
- second u is true => [[first u,newpred],:attl]
- [[first u,["and",newpred,second u]],:attl]
+ attl := [[first u,mkpf([newpred,second u],'and)],:attl]
second v is true => nil
attl := remove(attl,v)
attl :=
@@ -463,7 +461,7 @@ JoinInner(l,$e) ==
AddPredicate(op is [sig,oldpred,:implem],newpred) ==
newpred is true => op
oldpred is true => [sig,newpred,:implem]
- [sig,mkpf([oldpred,newpred],"and"),:implem]
+ [sig,mkpf([oldpred,newpred],'and),:implem]
FundamentalAncestors := [x for x in FundamentalAncestors | rest x]
--strip out the pointer to Principal Ancestor
c := categoryPrincipals bufferData principal
diff --git a/src/interp/sys-macros.lisp b/src/interp/sys-macros.lisp
index 301ab9b2..871a9668 100644
--- a/src/interp/sys-macros.lisp
+++ b/src/interp/sys-macros.lisp
@@ -478,7 +478,7 @@
(REMFLAG (CDR L) KEY))))
- (FLAG '(* + AND OR PROGN) 'NARY) ; flag for MKPF
+ (FLAG '(* + AND |and| OR |or| PROGN) 'NARY) ; flag for MKPF
(defun MKPF (L OP)