diff options
author | dos-reis <gdr@axiomatics.org> | 2008-12-22 03:43:33 +0000 |
---|---|---|
committer | dos-reis <gdr@axiomatics.org> | 2008-12-22 03:43:33 +0000 |
commit | a4c3f01ad687e6b8a29db845f725c00b06016f36 (patch) | |
tree | 0b8f8377d79151b0db7eb05949ef3e6b8c090b69 /src/interp | |
parent | 1c8e4a0198566b3b7eb56d257d5f22ea03b3f57b (diff) | |
download | open-axiom-a4c3f01ad687e6b8a29db845f725c00b06016f36.tar.gz |
* interp/i-eval.boot (evaluateType0): Check for builtin
constructors.
(evaluateType): Likewise.
* interp/i-spec2.boot (isType): Reject unsaturated constructors.
Diffstat (limited to 'src/interp')
-rw-r--r-- | src/interp/i-eval.boot | 8 | ||||
-rw-r--r-- | src/interp/i-spec2.boot | 2 |
2 files changed, 5 insertions, 5 deletions
diff --git a/src/interp/i-eval.boot b/src/interp/i-eval.boot index cf3028f3..7850f956 100644 --- a/src/interp/i-eval.boot +++ b/src/interp/i-eval.boot @@ -116,8 +116,8 @@ evaluateType0 form == op='Enumeration => form constructor? op => evaluateType1 form NIL - constructor? form => - ATOM form => evaluateType [form] + IDENTP form and niladicConstructorFromDB form => evaluateType [form] + IDENTP form and (constructor? form or form in $BuiltinConstructorNames) => throwEvalTypeMsg("S2IE0003",[form,form]) evaluateType form == @@ -150,8 +150,8 @@ evaluateType form == [op,:[['_:,sel,evaluateType type] for ['_:,sel,type] in argl]] op='Enumeration => form evaluateFormAsType form - constructor? form => - ATOM form => evaluateType [form] + IDENTP form and niladicConstructorFromDB form => evaluateType [form] + IDENTP form and (constructor? form or form in $BuiltinConstructorNames) => throwEvalTypeMsg("S2IE0003",[form,form]) evaluateFormAsType form diff --git a/src/interp/i-spec2.boot b/src/interp/i-spec2.boot index 5b3742ee..a4abcc75 100644 --- a/src/interp/i-spec2.boot +++ b/src/interp/i-spec2.boot @@ -731,7 +731,7 @@ isType t == op:=opOf t VECP op => isMap(op:= getUnname op) => NIL - op = 'Mapping => + op = 'Mapping and CONSP t => argTypes := [isType type for type in rest t] "or"/[null type for type in argTypes] => nil ['Mapping, :argTypes] |