diff options
Diffstat (limited to 'src/boot')
-rw-r--r-- | src/boot/ast.boot | 6 | ||||
-rw-r--r-- | src/boot/parser.boot | 6 | ||||
-rw-r--r-- | src/boot/tokens.boot | 3 |
3 files changed, 9 insertions, 6 deletions
diff --git a/src/boot/ast.boot b/src/boot/ast.boot index 3dce3667..3c921466 100644 --- a/src/boot/ast.boot +++ b/src/boot/ast.boot @@ -485,7 +485,7 @@ bfSUBLIS(p,e)== bfSUBLIS1(p,e)== p = nil => e f := first p - EQ(first f,e) => bfSUBLIS(p, rest f) + sameObject?(first f,e) => bfSUBLIS(p, rest f) bfSUBLIS1(rest p,e) defSheepAndGoats(x)== @@ -540,7 +540,7 @@ bfLET1(lhs,rhs) == bfMKPROGN [rhs1,:let1,g] bfCONTAINED(x,y)== - EQ(x,y) => true + sameObject?(x,y) => true atom y=> false bfCONTAINED(x,first y) or bfCONTAINED(x,rest y) @@ -1146,7 +1146,7 @@ bfCase(x,y)== atom x => x bfGenSymbol() body := ["CASE",["CAR", g], :bfCaseItems(g,y)] - EQ(g,x) => body + sameObject?(g,x) => body ["LET",[[g,x]],body] bfCaseItems: (%Thing,%List) -> %List diff --git a/src/boot/parser.boot b/src/boot/parser.boot index 03c2f639..cfa034d8 100644 --- a/src/boot/parser.boot +++ b/src/boot/parser.boot @@ -240,13 +240,13 @@ bpBacksetElse()== bpEqKey "ELSE" bpEqPeek s == - $stok is ["KEY",:.] and EQ(s,$ttok) + $stok is ["KEY",:.] and sameObject?(s,$ttok) bpEqKey s == - $stok is ["KEY",:.] and EQ(s,$ttok) and bpNext() + $stok is ["KEY",:.] and sameObject?(s,$ttok) and bpNext() bpEqKeyNextTok s == - $stok is ["KEY",:.] and EQ(s,$ttok) and bpNextToken() + $stok is ["KEY",:.] and sameObject?(s,$ttok) and bpNextToken() bpPileTrap() == bpMissing "BACKTAB" bpBrackTrap(x) == bpMissingMate("]",x) diff --git a/src/boot/tokens.boot b/src/boot/tokens.boot index 4b2cd544..c4cf1664 100644 --- a/src/boot/tokens.boot +++ b/src/boot/tokens.boot @@ -262,8 +262,10 @@ for i in [ _ ["exit", "EXIT"] , _ ["false", 'NIL] , _ ["first", "CAR"] , _ + ["float?", "FLOATP"] , _ ["fourth", "CADDDR"] , _ ["function","FUNCTION"] , _ + ["function?","FUNCTIONP"] , _ ["gensym", "GENSYM"] , _ ["genvar", "GENVAR"] , _ ["integer?","INTEGERP"] , _ @@ -292,6 +294,7 @@ for i in [ _ ["rest", "CDR"] , _ ["reverse", "REVERSE"] , _ ["sameObject?", "EQ" ] , _ + ["scalarEqual?","EQL" ] , _ ["second", "CADR"] , _ ["setDifference", "SETDIFFERENCE"] , _ ["setIntersection", "INTERSECTION"] , _ |