aboutsummaryrefslogtreecommitdiff
path: root/src/boot
diff options
context:
space:
mode:
authordos-reis <gdr@axiomatics.org>2009-08-19 08:47:00 +0000
committerdos-reis <gdr@axiomatics.org>2009-08-19 08:47:00 +0000
commit71cb17550511a6abb225030cb25c16bef8f31ef5 (patch)
tree41e1dc042870c6df23fd1e20cb92fac152a416e6 /src/boot
parentcd78da3860f838c41aedc3a0c475cfc8c23eaad3 (diff)
downloadopen-axiom-71cb17550511a6abb225030cb25c16bef8f31ef5.tar.gz
* boot/ast.boot: Consistently prefix AST names by "%".
* boot/translator.boot: Adjust. * boot/parser.boot: Likewise.
Diffstat (limited to 'src/boot')
-rw-r--r--src/boot/ast.boot94
-rw-r--r--src/boot/parser.boot12
-rw-r--r--src/boot/strap/ast.clisp124
-rw-r--r--src/boot/strap/parser.clisp13
-rw-r--r--src/boot/strap/translator.clisp12
-rw-r--r--src/boot/translator.boot16
6 files changed, 138 insertions, 133 deletions
diff --git a/src/boot/ast.boot b/src/boot/ast.boot
index 8fe59706..d02f7a8e 100644
--- a/src/boot/ast.boot
+++ b/src/boot/ast.boot
@@ -83,51 +83,51 @@ structure %Name ==
%Name(%Symbol)
structure %Ast ==
- Command(%String) -- includer command
+ %Command(%String) -- includer command
%Module(%Name,%List) -- module declaration
- Import(%String) -- import module
- ImportSignature(Name, Signature) -- import function declaration
+ %Import(%String) -- import module
+ %ImportSignature(%Name,%Signature) -- import function declaration
%TypeAlias(%Head, %List) -- type alias definition
- Signature(Name, Mapping) -- op: S -> T
- Mapping(Ast, %List) -- (S1, S2) -> T
- SuffixDot(Ast) -- x .
- Quote(Ast) -- 'x
- EqualName(Name) -- =x -- patterns
- Colon(Name) -- :x
- QualifiedName(Name, Name) -- m::x
+ %Signature(%Name,%Mapping) -- op: S -> T
+ %Mapping(%Ast, %List) -- (S1, S2) -> T
+ %SuffixDot(%Ast) -- x .
+ %Quote(%Ast) -- 'x
+ %EqualName(%Name) -- =x -- patterns
+ %Colon(%Name) -- :x
+ %QualifiedName(%Name,%Name) -- m::x
%DefaultValue(%Name,%Ast) -- opt. value for function param.
- Bracket(Ast) -- [x, y]
- UnboundedSegment(Ast) -- 3..
- BoundedSgement(Ast, Ast) -- 2..4
- Tuple(List) -- comma-separated expression sequence
- ColonAppend(Ast, Ast) -- [:y] or [x, :y]
- Is(Ast, Ast) -- e is p -- patterns
- Isnt(Ast, Ast) -- e isnt p -- patterns
- Reduce(Ast, Ast) -- +/[...]
- PrefixExpr(Name, Ast) -- #v
- Call(Ast,%Sequence) -- f(x, y , z)
- InfixExpr(Name, Ast, Ast) -- x + y
- ConstantDefinition(Name, Ast) -- x == y
- Definition(Name, List, Ast, Ast) -- f x == y
- Macro(Name, List, Ast) -- m x ==> y
- SuchThat(Ast) -- | p
- %Assignment(Ast, Ast) -- x := y
- While(Ast) -- while p -- iterator
- Until(Ast) -- until p -- iterator
- For(Ast, Ast, Ast) -- for x in e by k -- iterator
- Exit(Ast, Ast) -- p => x
- Iterators(List) -- list of iterators
- Cross(List) -- iterator cross product
- Repeat(%Sequence,Ast) -- while p repeat s
- Pile(%Sequence) -- pile of expression sequence
- Append(%Sequence) -- concatenate lists
- Case(Ast,%Sequence) -- case x of ...
- Return(Ast) -- return x
- %Throw(Ast) -- throw OutOfRange 3
- %Catch(Ast) -- catch OutOfRange
- %Try(Ast,%Sequence) -- try x / y catch DivisionByZero
- Where(Ast,%Sequence) -- e where f x == y
- Structure(Ast,%Sequence) -- structure Foo == ...
+ %Bracket(%Ast) -- [x, y]
+ %UnboundedSegment(%Ast) -- 3..
+ %BoundedSgement(%Ast,%Ast) -- 2..4
+ %Tuple(%List) -- comma-separated expression sequence
+ %ColonAppend(%Ast,%Ast) -- [:y] or [x, :y]
+ %Is(%Ast,%Ast) -- e is p -- patterns
+ %Isnt(%Ast,%Ast) -- e isnt p -- patterns
+ %Reduce(%Ast,%Ast) -- +/[...]
+ %PrefixExpr(%Name,%Ast) -- #v
+ %Call(%Ast,%Sequence) -- f(x, y , z)
+ %InfixExpr(%Name,%Ast,%Ast) -- x + y
+ %ConstantDefinition(%Name,%Ast) -- x == y
+ %Definition(%Name,%List,%Ast,%Ast) -- f x == y
+ %Macro(%Name,%List,%Ast) -- m x ==> y
+ %SuchThat(%Ast) -- | p
+ %Assignment(%Ast,%Ast) -- x := y
+ %While(%Ast) -- while p -- iterator
+ %Until(%Ast) -- until p -- iterator
+ %For(%Ast,%Ast,%Ast) -- for x in e by k -- iterator
+ %Implies(%Ast,%Ast) -- p => x
+ %Iterators(%List) -- list of iterators
+ %Cross(%List) -- iterator cross product
+ %Repeat(%Sequence,%Ast) -- while p repeat s
+ %Pile(%Sequence) -- pile of expression sequence
+ %Append(%Sequence) -- concatenate lists
+ %Case(%Ast,%Sequence) -- case x of ...
+ %Return(%Ast) -- return x
+ %Throw(%Ast) -- throw OutOfRange 3
+ %Catch(%Ast) -- catch OutOfRange
+ %Try(%Ast,%Sequence) -- try x / y catch DivisionByZero
+ %Where(%Ast,%Sequence) -- e where f x == y
+ %Structure(%Ast,%Sequence) -- structure Foo == ...
-- TRUE if we are currently building the syntax tree for an 'is'
-- expression.
@@ -208,7 +208,7 @@ bfSimpleDefinition(lhs,rhs) ==
$constantIdentifiers := [lhs,:$constantIdentifiers]
else if lhs is ["%Signature",id,.] then
$constantIdentifiers := [id,:$constantIdentifiers]
- ConstantDefinition(lhs,rhs)
+ %ConstantDefinition(lhs,rhs)
@@ -219,7 +219,7 @@ bfMDefinition(bflhsitems, bfrhs,body) ==
bfCompDef: %Thing -> %List
bfCompDef x ==
case x of
- ConstantDefinition(.,.) => x
+ %ConstantDefinition(.,.) => x
otherwise =>
x is [def, op, args, body] =>
bfDef(def,op,args,body)
@@ -1013,7 +1013,7 @@ shoeCompTran1 x==
shoeCompTran1 rest x
bfTagged(a,b)==
- null $op => Signature(a,b) -- surely a toplevel decl
+ null $op => %Signature(a,b) -- surely a toplevel decl
IDENTP a =>
EQ(b,"FLUID") => bfLET(compFluid a,NIL)
EQ(b,"fluid") => bfLET(compFluid a,NIL)
@@ -1636,8 +1636,8 @@ genSBCLnativeTranslation(op,s,t,op') ==
++ foreign signature `sig'. Here, `foreign' operationally means that
++ the entity is from the C language world.
genImportDeclaration(op, sig) ==
- sig isnt ["Signature", op', m] => coreError '"invalid signature"
- m isnt ["Mapping", t, s] => coreError '"invalid function type"
+ sig isnt ["%Signature", op', m] => coreError '"invalid signature"
+ m isnt ["%Mapping", t, s] => coreError '"invalid function type"
if not null s and SYMBOLP s then s := [s]
%hasFeature KEYWORD::GCL => genGCLnativeTranslation(op,s,t,op')
diff --git a/src/boot/parser.boot b/src/boot/parser.boot
index 68300d52..9d6b1a55 100644
--- a/src/boot/parser.boot
+++ b/src/boot/parser.boot
@@ -469,8 +469,8 @@ bpImport() ==
(bpSignature() or bpTrap()) and
(bpEqKey "FOR" or bpTrap()) and
(bpName() or bpTrap()) and
- bpPush ImportSignature(bpPop1(), bpPop1())
- bpPush Import bpPop1()
+ bpPush %ImportSignature(bpPop1(), bpPop1())
+ bpPush %Import bpPop1()
false
-- Parse a type alias defnition:
@@ -486,7 +486,7 @@ bpTypeAliasDefition() ==
++ Name COLON Mapping
bpSignature() ==
bpName() and bpEqKey "COLON" and bpMapping()
- and bpPush Signature(bpPop2(), bpPop1())
+ and bpPush %Signature(bpPop2(), bpPop1())
++ SimpleMapping:
++ Application
@@ -494,7 +494,7 @@ bpSignature() ==
bpSimpleMapping() ==
bpApplication() =>
bpEqKey "ARROW" and (bpApplication() or bpTrap()) and
- bpPush Mapping(bpPop1(), bfUntuple bpPop1())
+ bpPush %Mapping(bpPop1(), bfUntuple bpPop1())
true
false
@@ -513,7 +513,7 @@ bpArgtypeList() ==
bpMapping() ==
bpParenthesized function bpArgtypeList and
bpEqKey "ARROW" and bpApplication() and
- bpPush Mapping(bpPop1(), bfUntuple bpPop1())
+ bpPush %Mapping(bpPop1(), bfUntuple bpPop1())
or bpSimpleMapping()
bpCancel()==
@@ -610,7 +610,7 @@ bpApplication()==
bpTyping() ==
bpApplication() and
(bpEqKey "ARROW" and (bpApplication() or bpTrap()) and
- bpPush Mapping(bpPop1(), bfUntuple bpPop1()) or true) or bpMapping()
+ bpPush %Mapping(bpPop1(), bfUntuple bpPop1()) or true) or bpMapping()
++ Tagged:
++ Name : Typing
diff --git a/src/boot/strap/ast.clisp b/src/boot/strap/ast.clisp
index 01cde61b..0d4a44e8 100644
--- a/src/boot/strap/ast.clisp
+++ b/src/boot/strap/ast.clisp
@@ -29,104 +29,108 @@
(DEFUN |%Name| #0=(|bfVar#1|) (CONS '|%Name| (LIST . #0#)))
-(DEFUN |Command| #0=(|bfVar#2|) (CONS '|Command| (LIST . #0#)))
+(DEFUN |%Command| #0=(|bfVar#2|) (CONS '|%Command| (LIST . #0#)))
(DEFUN |%Module| #0=(|bfVar#3| |bfVar#4|)
(CONS '|%Module| (LIST . #0#)))
-(DEFUN |Import| #0=(|bfVar#5|) (CONS '|Import| (LIST . #0#)))
+(DEFUN |%Import| #0=(|bfVar#5|) (CONS '|%Import| (LIST . #0#)))
-(DEFUN |ImportSignature| #0=(|bfVar#6| |bfVar#7|)
- (CONS '|ImportSignature| (LIST . #0#)))
+(DEFUN |%ImportSignature| #0=(|bfVar#6| |bfVar#7|)
+ (CONS '|%ImportSignature| (LIST . #0#)))
(DEFUN |%TypeAlias| #0=(|bfVar#8| |bfVar#9|)
(CONS '|%TypeAlias| (LIST . #0#)))
-(DEFUN |Signature| #0=(|bfVar#10| |bfVar#11|)
- (CONS '|Signature| (LIST . #0#)))
+(DEFUN |%Signature| #0=(|bfVar#10| |bfVar#11|)
+ (CONS '|%Signature| (LIST . #0#)))
-(DEFUN |Mapping| #0=(|bfVar#12| |bfVar#13|)
- (CONS '|Mapping| (LIST . #0#)))
+(DEFUN |%Mapping| #0=(|bfVar#12| |bfVar#13|)
+ (CONS '|%Mapping| (LIST . #0#)))
-(DEFUN |SuffixDot| #0=(|bfVar#14|) (CONS '|SuffixDot| (LIST . #0#)))
+(DEFUN |%SuffixDot| #0=(|bfVar#14|) (CONS '|%SuffixDot| (LIST . #0#)))
-(DEFUN |Quote| #0=(|bfVar#15|) (CONS '|Quote| (LIST . #0#)))
+(DEFUN |%Quote| #0=(|bfVar#15|) (CONS '|%Quote| (LIST . #0#)))
-(DEFUN |EqualName| #0=(|bfVar#16|) (CONS '|EqualName| (LIST . #0#)))
+(DEFUN |%EqualName| #0=(|bfVar#16|) (CONS '|%EqualName| (LIST . #0#)))
-(DEFUN |Colon| #0=(|bfVar#17|) (CONS '|Colon| (LIST . #0#)))
+(DEFUN |%Colon| #0=(|bfVar#17|) (CONS '|%Colon| (LIST . #0#)))
-(DEFUN |QualifiedName| #0=(|bfVar#18| |bfVar#19|)
- (CONS '|QualifiedName| (LIST . #0#)))
+(DEFUN |%QualifiedName| #0=(|bfVar#18| |bfVar#19|)
+ (CONS '|%QualifiedName| (LIST . #0#)))
(DEFUN |%DefaultValue| #0=(|bfVar#20| |bfVar#21|)
(CONS '|%DefaultValue| (LIST . #0#)))
-(DEFUN |Bracket| #0=(|bfVar#22|) (CONS '|Bracket| (LIST . #0#)))
+(DEFUN |%Bracket| #0=(|bfVar#22|) (CONS '|%Bracket| (LIST . #0#)))
-(DEFUN |UnboundedSegment| #0=(|bfVar#23|)
- (CONS '|UnboundedSegment| (LIST . #0#)))
+(DEFUN |%UnboundedSegment| #0=(|bfVar#23|)
+ (CONS '|%UnboundedSegment| (LIST . #0#)))
-(DEFUN |BoundedSgement| #0=(|bfVar#24| |bfVar#25|)
- (CONS '|BoundedSgement| (LIST . #0#)))
+(DEFUN |%BoundedSgement| #0=(|bfVar#24| |bfVar#25|)
+ (CONS '|%BoundedSgement| (LIST . #0#)))
-(DEFUN |Tuple| #0=(|bfVar#26|) (CONS '|Tuple| (LIST . #0#)))
+(DEFUN |%Tuple| #0=(|bfVar#26|) (CONS '|%Tuple| (LIST . #0#)))
-(DEFUN |ColonAppend| #0=(|bfVar#27| |bfVar#28|)
- (CONS '|ColonAppend| (LIST . #0#)))
+(DEFUN |%ColonAppend| #0=(|bfVar#27| |bfVar#28|)
+ (CONS '|%ColonAppend| (LIST . #0#)))
-(DEFUN |Is| #0=(|bfVar#29| |bfVar#30|) (CONS '|Is| (LIST . #0#)))
+(DEFUN |%Is| #0=(|bfVar#29| |bfVar#30|) (CONS '|%Is| (LIST . #0#)))
-(DEFUN |Isnt| #0=(|bfVar#31| |bfVar#32|) (CONS '|Isnt| (LIST . #0#)))
+(DEFUN |%Isnt| #0=(|bfVar#31| |bfVar#32|)
+ (CONS '|%Isnt| (LIST . #0#)))
-(DEFUN |Reduce| #0=(|bfVar#33| |bfVar#34|)
- (CONS '|Reduce| (LIST . #0#)))
+(DEFUN |%Reduce| #0=(|bfVar#33| |bfVar#34|)
+ (CONS '|%Reduce| (LIST . #0#)))
-(DEFUN |PrefixExpr| #0=(|bfVar#35| |bfVar#36|)
- (CONS '|PrefixExpr| (LIST . #0#)))
+(DEFUN |%PrefixExpr| #0=(|bfVar#35| |bfVar#36|)
+ (CONS '|%PrefixExpr| (LIST . #0#)))
-(DEFUN |Call| #0=(|bfVar#37| |bfVar#38|) (CONS '|Call| (LIST . #0#)))
+(DEFUN |%Call| #0=(|bfVar#37| |bfVar#38|)
+ (CONS '|%Call| (LIST . #0#)))
-(DEFUN |InfixExpr| #0=(|bfVar#39| |bfVar#40| |bfVar#41|)
- (CONS '|InfixExpr| (LIST . #0#)))
+(DEFUN |%InfixExpr| #0=(|bfVar#39| |bfVar#40| |bfVar#41|)
+ (CONS '|%InfixExpr| (LIST . #0#)))
-(DEFUN |ConstantDefinition| #0=(|bfVar#42| |bfVar#43|)
- (CONS '|ConstantDefinition| (LIST . #0#)))
+(DEFUN |%ConstantDefinition| #0=(|bfVar#42| |bfVar#43|)
+ (CONS '|%ConstantDefinition| (LIST . #0#)))
-(DEFUN |Definition| #0=(|bfVar#44| |bfVar#45| |bfVar#46| |bfVar#47|)
- (CONS '|Definition| (LIST . #0#)))
+(DEFUN |%Definition| #0=(|bfVar#44| |bfVar#45| |bfVar#46| |bfVar#47|)
+ (CONS '|%Definition| (LIST . #0#)))
-(DEFUN |Macro| #0=(|bfVar#48| |bfVar#49| |bfVar#50|)
- (CONS '|Macro| (LIST . #0#)))
+(DEFUN |%Macro| #0=(|bfVar#48| |bfVar#49| |bfVar#50|)
+ (CONS '|%Macro| (LIST . #0#)))
-(DEFUN |SuchThat| #0=(|bfVar#51|) (CONS '|SuchThat| (LIST . #0#)))
+(DEFUN |%SuchThat| #0=(|bfVar#51|) (CONS '|%SuchThat| (LIST . #0#)))
(DEFUN |%Assignment| #0=(|bfVar#52| |bfVar#53|)
(CONS '|%Assignment| (LIST . #0#)))
-(DEFUN |While| #0=(|bfVar#54|) (CONS '|While| (LIST . #0#)))
+(DEFUN |%While| #0=(|bfVar#54|) (CONS '|%While| (LIST . #0#)))
-(DEFUN |Until| #0=(|bfVar#55|) (CONS '|Until| (LIST . #0#)))
+(DEFUN |%Until| #0=(|bfVar#55|) (CONS '|%Until| (LIST . #0#)))
-(DEFUN |For| #0=(|bfVar#56| |bfVar#57| |bfVar#58|)
- (CONS '|For| (LIST . #0#)))
+(DEFUN |%For| #0=(|bfVar#56| |bfVar#57| |bfVar#58|)
+ (CONS '|%For| (LIST . #0#)))
-(DEFUN |Exit| #0=(|bfVar#59| |bfVar#60|) (CONS '|Exit| (LIST . #0#)))
+(DEFUN |%Implies| #0=(|bfVar#59| |bfVar#60|)
+ (CONS '|%Implies| (LIST . #0#)))
-(DEFUN |Iterators| #0=(|bfVar#61|) (CONS '|Iterators| (LIST . #0#)))
+(DEFUN |%Iterators| #0=(|bfVar#61|) (CONS '|%Iterators| (LIST . #0#)))
-(DEFUN |Cross| #0=(|bfVar#62|) (CONS '|Cross| (LIST . #0#)))
+(DEFUN |%Cross| #0=(|bfVar#62|) (CONS '|%Cross| (LIST . #0#)))
-(DEFUN |Repeat| #0=(|bfVar#63| |bfVar#64|)
- (CONS '|Repeat| (LIST . #0#)))
+(DEFUN |%Repeat| #0=(|bfVar#63| |bfVar#64|)
+ (CONS '|%Repeat| (LIST . #0#)))
-(DEFUN |Pile| #0=(|bfVar#65|) (CONS '|Pile| (LIST . #0#)))
+(DEFUN |%Pile| #0=(|bfVar#65|) (CONS '|%Pile| (LIST . #0#)))
-(DEFUN |Append| #0=(|bfVar#66|) (CONS '|Append| (LIST . #0#)))
+(DEFUN |%Append| #0=(|bfVar#66|) (CONS '|%Append| (LIST . #0#)))
-(DEFUN |Case| #0=(|bfVar#67| |bfVar#68|) (CONS '|Case| (LIST . #0#)))
+(DEFUN |%Case| #0=(|bfVar#67| |bfVar#68|)
+ (CONS '|%Case| (LIST . #0#)))
-(DEFUN |Return| #0=(|bfVar#69|) (CONS '|Return| (LIST . #0#)))
+(DEFUN |%Return| #0=(|bfVar#69|) (CONS '|%Return| (LIST . #0#)))
(DEFUN |%Throw| #0=(|bfVar#70|) (CONS '|%Throw| (LIST . #0#)))
@@ -134,11 +138,11 @@
(DEFUN |%Try| #0=(|bfVar#72| |bfVar#73|) (CONS '|%Try| (LIST . #0#)))
-(DEFUN |Where| #0=(|bfVar#74| |bfVar#75|)
- (CONS '|Where| (LIST . #0#)))
+(DEFUN |%Where| #0=(|bfVar#74| |bfVar#75|)
+ (CONS '|%Where| (LIST . #0#)))
-(DEFUN |Structure| #0=(|bfVar#76| |bfVar#77|)
- (CONS '|Structure| (LIST . #0#)))
+(DEFUN |%Structure| #0=(|bfVar#76| |bfVar#77|)
+ (CONS '|%Structure| (LIST . #0#)))
(DEFPARAMETER |$inDefIS| NIL)
@@ -241,7 +245,7 @@
(EQ (CDR |ISTMP#2|) NIL))))))
(SETQ |$constantIdentifiers|
(CONS |id| |$constantIdentifiers|))))
- (|ConstantDefinition| |lhs| |rhs|)))))
+ (|%ConstantDefinition| |lhs| |rhs|)))))
(DECLAIM (FTYPE (FUNCTION (|%Thing| |%Thing| |%Thing|) |%List|)
|bfMDefinition|))
@@ -259,7 +263,7 @@
(SETQ |bfVar#78| |x|)
(SETQ |bfVar#79| (CDR |bfVar#78|))
(CASE (CAR |bfVar#78|)
- (|ConstantDefinition| |x|)
+ (|%ConstantDefinition| |x|)
(T (COND
((AND (CONSP |x|)
(PROGN
@@ -1760,7 +1764,7 @@
(DEFUN |bfTagged| (|a| |b|)
(DECLARE (SPECIAL |$typings| |$op|))
(COND
- ((NULL |$op|) (|Signature| |a| |b|))
+ ((NULL |$op|) (|%Signature| |a| |b|))
((IDENTP |a|)
(COND
((EQ |b| 'FLUID) (|bfLET| (|compFluid| |a|) NIL))
@@ -2997,7 +3001,7 @@
(PROG (|s| |t| |m| |ISTMP#2| |op'| |ISTMP#1|)
(RETURN
(COND
- ((NOT (AND (CONSP |sig|) (EQ (CAR |sig|) '|Signature|)
+ ((NOT (AND (CONSP |sig|) (EQ (CAR |sig|) '|%Signature|)
(PROGN
(SETQ |ISTMP#1| (CDR |sig|))
(AND (CONSP |ISTMP#1|)
@@ -3010,7 +3014,7 @@
(SETQ |m| (CAR |ISTMP#2|))
#0='T)))))))
(|coreError| "invalid signature"))
- ((NOT (AND (CONSP |m|) (EQ (CAR |m|) '|Mapping|)
+ ((NOT (AND (CONSP |m|) (EQ (CAR |m|) '|%Mapping|)
(PROGN
(SETQ |ISTMP#1| (CDR |m|))
(AND (CONSP |ISTMP#1|)
diff --git a/src/boot/strap/parser.clisp b/src/boot/strap/parser.clisp
index 56275620..0607ff77 100644
--- a/src/boot/strap/parser.clisp
+++ b/src/boot/strap/parser.clisp
@@ -499,8 +499,8 @@
(OR (|bpEqKey| 'FOR) (|bpTrap|))
(OR (|bpName|) (|bpTrap|))
(|bpPush|
- (|ImportSignature| (|bpPop1|) (|bpPop1|))))))
- (#0='T (|bpPush| (|Import| (|bpPop1|)))))))
+ (|%ImportSignature| (|bpPop1|) (|bpPop1|))))))
+ (#0='T (|bpPush| (|%Import| (|bpPop1|)))))))
(#0# NIL)))))
(DEFUN |bpTypeAliasDefition| ()
@@ -509,14 +509,14 @@
(DEFUN |bpSignature| ()
(AND (|bpName|) (|bpEqKey| 'COLON) (|bpMapping|)
- (|bpPush| (|Signature| (|bpPop2|) (|bpPop1|)))))
+ (|bpPush| (|%Signature| (|bpPop2|) (|bpPop1|)))))
(DEFUN |bpSimpleMapping| ()
(COND
((|bpApplication|)
(PROGN
(AND (|bpEqKey| 'ARROW) (OR (|bpApplication|) (|bpTrap|))
- (|bpPush| (|Mapping| (|bpPop1|) (|bfUntuple| (|bpPop1|)))))
+ (|bpPush| (|%Mapping| (|bpPop1|) (|bfUntuple| (|bpPop1|)))))
T))
('T NIL)))
@@ -525,7 +525,7 @@
(DEFUN |bpMapping| ()
(OR (AND (|bpParenthesized| #'|bpArgtypeList|) (|bpEqKey| 'ARROW)
(|bpApplication|)
- (|bpPush| (|Mapping| (|bpPop1|) (|bfUntuple| (|bpPop1|)))))
+ (|bpPush| (|%Mapping| (|bpPop1|) (|bfUntuple| (|bpPop1|)))))
(|bpSimpleMapping|)))
(DEFUN |bpCancel| ()
@@ -633,7 +633,8 @@
(OR (AND (|bpEqKey| 'ARROW)
(OR (|bpApplication|) (|bpTrap|))
(|bpPush|
- (|Mapping| (|bpPop1|) (|bfUntuple| (|bpPop1|)))))
+ (|%Mapping| (|bpPop1|)
+ (|bfUntuple| (|bpPop1|)))))
T))
(|bpMapping|)))
diff --git a/src/boot/strap/translator.clisp b/src/boot/strap/translator.clisp
index cb67bdfb..fe895323 100644
--- a/src/boot/strap/translator.clisp
+++ b/src/boot/strap/translator.clisp
@@ -539,7 +539,7 @@
(PROG (|argTypes| |ISTMP#2| |valType| |ISTMP#1|)
(RETURN
(COND
- ((AND (CONSP |t|) (EQ (CAR |t|) '|Mapping|)
+ ((AND (CONSP |t|) (EQ (CAR |t|) '|%Mapping|)
(PROGN
(SETQ |ISTMP#1| (CDR |t|))
(AND (CONSP |ISTMP#1|)
@@ -569,7 +569,7 @@
(SETQ |bfVar#9| |d|)
(SETQ |bfVar#10| (CDR |bfVar#9|))
(CASE (CAR |bfVar#9|)
- (|Signature|
+ (|%Signature|
(LET ((|n| (CAR |bfVar#10|)) (|t| (CADR |bfVar#10|)))
(|genDeclaration| |n| |t|)))
(T (|coreError| "signature expected")))))))
@@ -630,7 +630,7 @@
(SETQ |bfVar#16| |b|)
(SETQ |bfVar#17| (CDR |bfVar#16|))
(CASE (CAR |bfVar#16|)
- (|Signature|
+ (|%Signature|
(LET ((|op| (CAR |bfVar#17|)) (|t| (CADR |bfVar#17|)))
(LIST (|maybeExportDecl| (|genDeclaration| |op| |t|)
|export?|))))
@@ -656,7 +656,7 @@
(|translateToplevel| |d| T))
|bfVar#15|))))
(SETQ |bfVar#14| (CDR |bfVar#14|))))))))
- (|Import|
+ (|%Import|
(LET ((|m| (CAR |bfVar#17|)))
(PROGN
(COND
@@ -664,7 +664,7 @@
"skip"))
(|bootImport| (STRING |m|))))
(LIST (LIST 'IMPORT-MODULE (STRING |m|))))))
- (|ImportSignature|
+ (|%ImportSignature|
(LET ((|x| (CAR |bfVar#17|))
(|sig| (CADR |bfVar#17|)))
(|genImportDeclaration| |x| |sig|)))
@@ -673,7 +673,7 @@
(|rhs| (CADR |bfVar#17|)))
(LIST (|maybeExportDecl|
(|genTypeAlias| |lhs| |rhs|) |export?|))))
- (|ConstantDefinition|
+ (|%ConstantDefinition|
(LET ((|lhs| (CAR |bfVar#17|))
(|rhs| (CADR |bfVar#17|)))
(PROGN
diff --git a/src/boot/translator.boot b/src/boot/translator.boot
index c3e50f44..bfc91deb 100644
--- a/src/boot/translator.boot
+++ b/src/boot/translator.boot
@@ -380,7 +380,7 @@ shoeOutParse stream ==
++ Generate a global signature declaration for symbol `n'.
genDeclaration(n,t) ==
- t is ["Mapping",valType,argTypes] =>
+ t is ["%Mapping",valType,argTypes] =>
if bfTupleP argTypes then argTypes := rest argTypes
if not null argTypes and SYMBOLP argTypes
then argTypes := [argTypes]
@@ -391,7 +391,7 @@ genDeclaration(n,t) ==
++ Translate the signature declaration `d' to its Lisp equivalent.
translateSignatureDeclaration d ==
case d of
- Signature(n,t) => genDeclaration(n,t)
+ %Signature(n,t) => genDeclaration(n,t)
otherwise => coreError '"signature expected"
++ A non declarative expression `expr' appears at toplevel and its
@@ -417,7 +417,7 @@ translateToplevel(b,export?) ==
atom b => [b] -- generally happens in interactive mode.
b is ["TUPLE",:xs] => [maybeExportDecl(x,export?) for x in xs]
case b of
- Signature(op,t) =>
+ %Signature(op,t) =>
[maybeExportDecl(genDeclaration(op,t),export?)]
%Module(m,ds) =>
@@ -426,18 +426,18 @@ translateToplevel(b,export?) ==
[["PROVIDE", STRING m],
:[first translateToplevel(d,true) for d in ds]]
- Import(m) =>
+ %Import(m) =>
if getOptionValue "import" ~= '"skip" then
bootImport STRING m
[["IMPORT-MODULE", STRING m]]
- ImportSignature(x, sig) =>
+ %ImportSignature(x, sig) =>
genImportDeclaration(x, sig)
%TypeAlias(lhs, rhs) =>
[maybeExportDecl(genTypeAlias(lhs,rhs),export?)]
- ConstantDefinition(lhs,rhs) =>
+ %ConstantDefinition(lhs,rhs) =>
sig := nil
if lhs is ["%Signature",n,t] then
sig := maybeExportDecl(genDeclaration(n,t),export?)
@@ -713,7 +713,7 @@ PSTTOMC string==
$GenVarCounter := 0
shoePCompileTrees shoeTransformString string
-BOOTLOOP ()==
+BOOTLOOP() ==
a:=READ_-LINE()
#a=0=>
WRITE_-LINE '"Boot Loop; to exit type ] "
@@ -727,7 +727,7 @@ BOOTLOOP ()==
PSTTOMC [a]
BOOTLOOP()
-BOOTPO ()==
+BOOTPO() ==
a:=READ_-LINE()
#a=0=>
WRITE_-LINE '"Boot Loop; to exit type ] "