aboutsummaryrefslogtreecommitdiff
path: root/src/interp/info.boot
diff options
context:
space:
mode:
authordos-reis <gdr@axiomatics.org>2009-06-10 09:34:58 +0000
committerdos-reis <gdr@axiomatics.org>2009-06-10 09:34:58 +0000
commitc020ac99c5016824cfe8fab756a15f73264c38d0 (patch)
tree9eadb72c266c508efea9f775452d41a4ff10b29d /src/interp/info.boot
parent879b9de5aaa0c3e717e3799c35af483816bac0da (diff)
downloadopen-axiom-c020ac99c5016824cfe8fab756a15f73264c38d0.tar.gz
* interp/parse.boot (parseHas): Preserve unnamed category forms.
* interp/i-funsel.boot (hasCaty): Recursively look into Joins. * interp/interop.boot (newHasCategory): Likewise. * interp/compiler.boot (compHasFormat): Handle unnamed categories. * interp/info.boot (knownInfo): Likewise.
Diffstat (limited to 'src/interp/info.boot')
-rw-r--r--src/interp/info.boot7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/interp/info.boot b/src/interp/info.boot
index 23a15dfc..293b1e40 100644
--- a/src/interp/info.boot
+++ b/src/interp/info.boot
@@ -174,10 +174,15 @@ knownInfo pred ==
pred is ["has",name,cat] =>
cat is ["ATTRIBUTE",:a] => knownInfo ["ATTRIBUTE",name,:a]
cat is ["SIGNATURE",:a] => knownInfo ["SIGNATURE",name,:a]
+ -- unnamed category expressions imply structural checks.
+ cat is ["Join",:.] => and/[knownInfo ["has",name,c] for c in rest cat]
+ cat is ["CATEGORY",.,:atts] =>
+ and/[knownInfo hasToInfo ["has",name,att] for att in atts]
name is ['Union,:.] => false
+ -- we have a named category expression
v:= compForMode(name,$EmptyMode,$e) or return
stackAndThrow('"can't find category of %1pb",[name])
- vmode := second v
+ vmode := v.mode
cat = vmode => true
vmode is ["Join",:l] and member(cat,l) => true
[vv,.,.]:= compMakeCategoryObject(vmode,$e) or return