aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordos-reis <gdr@axiomatics.org>2010-05-09 21:36:45 +0000
committerdos-reis <gdr@axiomatics.org>2010-05-09 21:36:45 +0000
commit3d51abbf17fa58fadbfa59757f50908488f6f9d9 (patch)
tree7fd28af0acab689ee3cc00bd31550ab61ce842d4
parentc758c27852f049e021da8855a290dd876e3b7050 (diff)
downloadopen-axiom-3d51abbf17fa58fadbfa59757f50908488f6f9d9.tar.gz
More cleanups
-rw-r--r--src/boot/ast.boot6
-rw-r--r--src/interp/cstream.boot8
-rw-r--r--src/interp/diagnostics.boot8
-rw-r--r--src/interp/fortcall.boot4
-rw-r--r--src/interp/g-util.boot4
-rw-r--r--src/interp/ht-util.boot2
-rw-r--r--src/interp/i-intern.boot4
-rw-r--r--src/interp/i-object.boot2
-rw-r--r--src/interp/i-parser.boot12
-rw-r--r--src/interp/int-top.boot6
-rw-r--r--src/interp/intfile.boot2
-rw-r--r--src/interp/mark.boot2
-rw-r--r--src/interp/msgdb.boot2
-rw-r--r--src/interp/newfort.boot14
-rw-r--r--src/interp/pile.boot20
-rw-r--r--src/interp/ptrees.boot4
-rw-r--r--src/interp/sys-utility.boot6
17 files changed, 53 insertions, 53 deletions
diff --git a/src/boot/ast.boot b/src/boot/ast.boot
index 263108e1..3ad7d4d8 100644
--- a/src/boot/ast.boot
+++ b/src/boot/ast.boot
@@ -475,7 +475,7 @@ bfSUBLIS1(p,e)==
p = nil => e
f := first p
EQ(first f,e) => bfSUBLIS(p, rest f)
- bfSUBLIS1(cdr p,e)
+ bfSUBLIS1(rest p,e)
defSheepAndGoats(x)==
case x of
@@ -531,7 +531,7 @@ bfLET1(lhs,rhs) ==
bfCONTAINED(x,y)==
EQ(x,y) => true
atom y=> false
- bfCONTAINED(x,car y) or bfCONTAINED(x,cdr y)
+ bfCONTAINED(x,first y) or bfCONTAINED(x,rest y)
bfLET2(lhs,rhs) ==
IDENTP lhs => bfLetForm(lhs,rhs)
@@ -901,7 +901,7 @@ shoeCompTran1 x==
MEMQ(x,$dollarVars)=>$dollarVars
[x,:$dollarVars]
nil
- U:=car x
+ U:=first x
U = "QUOTE" => nil
x is ["L%T",l,r] =>
x.first := "SETQ"
diff --git a/src/interp/cstream.boot b/src/interp/cstream.boot
index b6a3d311..c0913788 100644
--- a/src/interp/cstream.boot
+++ b/src/interp/cstream.boot
@@ -73,7 +73,7 @@ incZip1(:z)==
[g,f1,f2]:=z
StreamNull f1 => StreamNil
StreamNull f2 => StreamNil
- [FUNCALL(g,car f1,car f2),:incZip(g,cdr f1,cdr f2)]
+ [FUNCALL(g,first f1,first f2),:incZip(g,rest f1,rest f2)]
incAppend(x,y)==Delay(function incAppend1,[x,y])
@@ -83,14 +83,14 @@ incAppend1(:z)==
then if StreamNull y
then StreamNil
else y
- else [car x,:incAppend(cdr x,y)]
+ else [first x,:incAppend(rest x,y)]
next(f,s)==Delay(function next1,[f,s])
next1(:z)==
[f,s]:=z
StreamNull s=> StreamNil
h:= apply(f, [s])
- incAppend(car h,next(f,cdr h))
+ incAppend(first h,next(f,rest h))
nextown(f,g,s)==Delay(function nextown1,[f,g,s])
nextown1 (:z)==
@@ -100,7 +100,7 @@ nextown1 (:z)==
StreamNil
StreamNull s
h:=spadcall2 (f, s)
- incAppend(car h,nextown(f,g,cdr h))
+ incAppend(first h,nextown(f,g,rest h))
nextown2(f,g,e,x) ==
nextown([f,:e],[g,:e],x)
diff --git a/src/interp/diagnostics.boot b/src/interp/diagnostics.boot
index 21e15092..a4cd8dca 100644
--- a/src/interp/diagnostics.boot
+++ b/src/interp/diagnostics.boot
@@ -85,8 +85,8 @@ MESSAGEPRINT_-1 x ==
IDENTP x => PRINC x
atom x => PRINC x
PRINC '"("
- MESSAGEPRINT_-1 car x
- MESSAGEPRINT_-2 cdr x
+ MESSAGEPRINT_-1 first x
+ MESSAGEPRINT_-2 rest x
PRINC '")"
MESSAGEPRINT_-2 x ==
@@ -95,6 +95,6 @@ MESSAGEPRINT_-2 x ==
PRINC '" . "
MESSAGEPRINT_-1 x
PRINC '" "
- MESSAGEPRINT_-1 car x
- MESSAGEPRINT_-2 cdr x
+ MESSAGEPRINT_-1 first x
+ MESSAGEPRINT_-2 rest x
diff --git a/src/interp/fortcall.boot b/src/interp/fortcall.boot
index 9c2260a1..1071470e 100644
--- a/src/interp/fortcall.boot
+++ b/src/interp/fortcall.boot
@@ -50,7 +50,7 @@ makeFort(name,args,decls,results,returnType,aspInfo) ==
-- and a stub Axiom function to process its arguments.
-- the following is a list of objects for which values need not be
-- passed by the user.
- dummies := [second(u) for u in args | EQUAL(car u,0)]
+ dummies := [second(u) for u in args | EQUAL(first u,0)]
args := [untangle2(u) for u in args] -- lose spad Union representation
where untangle2 u ==
atom (v := rest(u)) => v
@@ -395,7 +395,7 @@ complexRows z ==
-- make them look like a Fortran vector!
[:[:pair2list(u.i) for u in z] for i in 0..#(z.0)-1]
-pair2list u == [car u,cdr u]
+pair2list u == [first u,rest u]
vec2Lists1 u == [u.i for i in 0..#u-1]
vec2Lists u == [vec2Lists1 u.i for i in 0..#u-1]
diff --git a/src/interp/g-util.boot b/src/interp/g-util.boot
index bd50fd14..f2ddb1b8 100644
--- a/src/interp/g-util.boot
+++ b/src/interp/g-util.boot
@@ -142,8 +142,8 @@ mkList u ==
ELEMN(x, n, d) ==
null x => d
- n = 1 => car x
- ELEMN(cdr x, n-1, d)
+ n = 1 => first x
+ ELEMN(rest x, n-1, d)
PPtoFile(x, fname) ==
stream := DEFIOSTREAM([['MODE, :'OUTPUT], ['FILE, :fname]], 80, 0)
diff --git a/src/interp/ht-util.boot b/src/interp/ht-util.boot
index ad02d338..440fbddf 100644
--- a/src/interp/ht-util.boot
+++ b/src/interp/ht-util.boot
@@ -372,7 +372,7 @@ renamePatternVariables1(condList, substList, patVars) ==
cond is ['isDomain, pv, pattern] or cond is ['ofCategory, pv, pattern]
or cond is ['Satisfies, pv, cond] =>
if pv = $EmptyMode then nsubst := substList
- else nsubst := [[pv, :car patVars], :substList]
+ else nsubst := [[pv, :first patVars], :substList]
renamePatternVariables1(restConds, nsubst, rest patVars)
substList
diff --git a/src/interp/i-intern.boot b/src/interp/i-intern.boot
index 12d02705..5700924c 100644
--- a/src/interp/i-intern.boot
+++ b/src/interp/i-intern.boot
@@ -307,8 +307,8 @@ flagArguments(op, nargs) ==
signatureFromModemap m ==
[sig,pred,:.] := m
pred = true => rest sig
- car pred = "AND" =>
- sl := [[a,:b] for [.,a,b] in cdr pred]
+ first pred = "AND" =>
+ sl := [[a,:b] for [.,a,b] in rest pred]
rest SUBLIS(sl,sig)
collectDefTypesAndPreds args ==
diff --git a/src/interp/i-object.boot b/src/interp/i-object.boot
index 460b76c4..c8b9774d 100644
--- a/src/interp/i-object.boot
+++ b/src/interp/i-object.boot
@@ -442,7 +442,7 @@ srcPosDisplay(sp) ==
getFlagArgsPos t ==
VECP t => getAtree(t, 'flagArgsPos)
atom t => keyedSystemError("S2II0001",[t])
- getFlagArgsPos car t
+ getFlagArgsPos first t
--% Transfer of VAT properties.
diff --git a/src/interp/i-parser.boot b/src/interp/i-parser.boot
index 828961d9..10959f93 100644
--- a/src/interp/i-parser.boot
+++ b/src/interp/i-parser.boot
@@ -41,11 +41,11 @@ namespace BOOT
++ returns the list of tokens making up a line in the stream `s'
tokenizeLine s ==
- [dq, stream] := car s
+ [dq, stream] := first s
[lines, rest] := ncloopDQlines(dq, $lines)
setCurrentLine(mkLineList lines)
$lines := rest
- [[npParse dqToList dq], :cdr s]
+ [[npParse dqToList dq], :rest s]
++ parse the IO stream `s' obtained from file `f'
parseStream(s, f) ==
@@ -58,15 +58,15 @@ parseStream(s, f) ==
++ return the list of all tokens making up the stream `s'
collectTokens s ==
StreamNull s => nil
- ts := car s
- [ts, :collectTokens cdr s]
+ ts := first s
+ [ts, :collectTokens rest s]
++ return the list of parsed lines from stream `s'. `p' is the list
++ of parsed lines collected so far.
collectParsedLines(s, p) ==
StreamNull s => p
- ptree := car s
- collectParsedLines(cdr s, [:p, ptree])
+ ptree := first s
+ collectParsedLines(rest s, [:p, ptree])
++ parse the whole file `file'. Returns a list of parse tree
++ containing full source location information.
diff --git a/src/interp/int-top.boot b/src/interp/int-top.boot
index ebef2d83..67242955 100644
--- a/src/interp/int-top.boot
+++ b/src/interp/int-top.boot
@@ -317,10 +317,10 @@ streamChop(n,s)==
else if EQL(n,0)
then [nil,s]
else
- [a,b]:= streamChop(n-1,cdr s)
- line:=car s
+ [a,b]:= streamChop(n-1,rest s)
+ line:=first s
c:=ncloopPrefix?('")command",rest line)
- d:= [car line,:(if c then c else cdr line)]
+ d:= [first line,:(if c then c else rest line)]
[[d,:a],b]
ncloopPrintLines lines ==
diff --git a/src/interp/intfile.boot b/src/interp/intfile.boot
index fdd5e519..f89cb3cf 100644
--- a/src/interp/intfile.boot
+++ b/src/interp/intfile.boot
@@ -57,7 +57,7 @@ shoeStrings (stream)==
if a.0 ~= char " "
then ['"",stream]
else
- [h,t]:=shoeStrings(cdr stream)
+ [h,t]:=shoeStrings(rest stream)
[strconc(a,h),t]
--fetchKeyedMsg(key,b)== GET(key,"MSGS")
diff --git a/src/interp/mark.boot b/src/interp/mark.boot
index d1469405..ce5c7b3a 100644
--- a/src/interp/mark.boot
+++ b/src/interp/mark.boot
@@ -1541,4 +1541,4 @@ for x in [["%LET", :"compSetq"],_
["SEQ", :"compSeq"],_
["SETQ", :"compSetq"],_
["VECTOR", :"compVector"]] repeat
- MAKEPROP(car x, "special", cdr x)
+ MAKEPROP(first x, "special", rest x)
diff --git a/src/interp/msgdb.boot b/src/interp/msgdb.boot
index 18444188..8df46589 100644
--- a/src/interp/msgdb.boot
+++ b/src/interp/msgdb.boot
@@ -797,7 +797,7 @@ brightPrintCenterAsTeX(x, out == $OutputStream) ==
while lst and not first(lst) = "%l" repeat
words := [first lst,: words]
lst := rest lst
- if lst then lst := cdr lst
+ if lst then lst := rest lst
sayString('"\centerline{",out)
words := nreverse words
for zz in words repeat
diff --git a/src/interp/newfort.boot b/src/interp/newfort.boot
index 5e5e01a0..ccd1de1d 100644
--- a/src/interp/newfort.boot
+++ b/src/interp/newfort.boot
@@ -716,7 +716,7 @@ fortFormatCharacterTypes(names) ==
#u=2 => sortedByLength := insertEntry(second u,first u,sortedByLength)
genuineArrays := [u,:genuineArrays]
for u in sortedByLength repeat
- fortFormatTypes1(mkCharName car u, [STRINGIMAGE(s) for s in cdr(u)]) where
+ fortFormatTypes1(mkCharName car u, [STRINGIMAGE(s) for s in rest(u)]) where
mkCharName v == strconc("CHARACTER*(",STRINGIMAGE v,")")
if (not null genuineArrays) then
fortFormatTypes1('"CHARACTER",mkParameterList2 genuineArrays) where
@@ -905,11 +905,11 @@ segment l ==
var := NTH(1,e)
exprs := segment1(third e,
$maximumFortranExpressionLength-1-fortExpSize var)
- s:= [:[['"=",var,car exprs],:cdr exprs],:s]
+ s:= [:[['"=",var,first exprs],:rest exprs],:s]
else if LISTP(e) and first e = '"RETURN" then
exprs := segment1(second e,
$maximumFortranExpressionLength-2-fortExpSize first e)
- s := [:[[first e,car exprs],:cdr exprs],:s]
+ s := [:[[first e,first exprs],:rest exprs],:s]
else s:= [e,:s]
reverse s
@@ -929,9 +929,9 @@ segment1(e,maxSize) ==
newE := [:newE,NTH(i-1,e)]
-- this ones too big.
exprs := segment2(NTH(i-1,e),safeSize)
- expressions := [:(cdr exprs),:expressions]
- newE := [:newE,(car exprs)]
- safeSize := safeSize - fortExpSize car exprs
+ expressions := [:(rest exprs),:expressions]
+ newE := [:newE,(first exprs)]
+ safeSize := safeSize - fortExpSize first exprs
[newE,:expressions]
segment2(e,topSize) ==
@@ -944,7 +944,7 @@ segment2(e,topSize) ==
subE := NTH(i-1,e)
(subSize := fortExpSize subE) > maxSize =>
subE := segment2(subE,maxSize)
- exprs := [:(cdr subE),:exprs]
+ exprs := [:(rest subE),:exprs]
if (subSize := fortExpSize first subE) <= topSize then
newE := [:newE,first subE]
topSize := topSize - subSize
diff --git a/src/interp/pile.boot b/src/interp/pile.boot
index 923adeb9..174bfe56 100644
--- a/src/interp/pile.boot
+++ b/src/interp/pile.boot
@@ -57,7 +57,7 @@ insertpile (s)==
if npNull s
then [false,0,[],s]
else
- [h,t]:=[car s,cdr s]
+ [h,t]:=[first s,rest s]
if pilePlusComment h
then
[h1,t1]:=pilePlusComments s
@@ -72,7 +72,7 @@ pilePlusComments s==
if npNull s
then [[],s]
else
- [h,t]:=[car s,cdr s]
+ [h,t]:=[first s,rest s]
if pilePlusComment h
then
[h1,t1]:=pilePlusComments t
@@ -83,7 +83,7 @@ pileTree(n,s)==
if npNull s
then [false,n,[],s]
else
- [h,t]:=[car s,cdr s]
+ [h,t]:=[first s,rest s]
hh:=pileColumn first h
if hh > n
then pileForests(first h,hh,t)
@@ -93,7 +93,7 @@ eqpileTree(n,s)==
if npNull s
then [false,n,[],s]
else
- [h,t]:=[car s,cdr s]
+ [h,t]:=[first s,rest s]
hh:=pileColumn first h
if hh = n
then pileForests(first h,hh,t)
@@ -128,9 +128,9 @@ pileCtree(x,y)==dqAppend(x,pileCforest y)
pileCforest x==
if null x
then []
- else if null cdr x
+ else if null rest x
then
- f:= car x
+ f:= first x
if EQ(tokPart CAAR f,"IF")
then enPile f
else f
@@ -142,12 +142,12 @@ lastTokPosn t== tokPosn second t
separatePiles x==
if null x
then []
- else if null cdr x
- then car x
+ else if null rest x
+ then first x
else
- a:=car x
+ a:=first x
semicolon:=dqUnit tokConstruct("key", "BACKSET",lastTokPosn a)
- dqConcat [a,semicolon,separatePiles cdr x]
+ dqConcat [a,semicolon,separatePiles rest x]
enPile x==
dqConcat [dqUnit tokConstruct("key","SETTAB",firstTokPosn x),
diff --git a/src/interp/ptrees.boot b/src/interp/ptrees.boot
index b152d326..1d3848ee 100644
--- a/src/interp/ptrees.boot
+++ b/src/interp/ptrees.boot
@@ -161,8 +161,8 @@ pfNotArg pf == second pf -- was ==>
pfEnSequence a==
if null a
then pfTuple pfListOf a
- else if null cdr a
- then car a
+ else if null rest a
+ then first a
else pfSequence pfListOf a
pfFromDom(dom,expr)==
if pfApplication? expr
diff --git a/src/interp/sys-utility.boot b/src/interp/sys-utility.boot
index 2a4b7024..ba7aab89 100644
--- a/src/interp/sys-utility.boot
+++ b/src/interp/sys-utility.boot
@@ -132,10 +132,10 @@ CONTAINED(x,y) == main where
equal(x,y)
eq(x,y) ==
atom y => EQ(x,y)
- eq(x, car y) or eq(x, cdr y)
+ eq(x, first y) or eq(x, rest y)
equal(x,y) ==
atom y => EQUAL(x,y)
- equal(x, car y) or equal(x, cdr y)
+ equal(x, first y) or equal(x, rest y)
++ Returns all the keys of association list `x'
-- ??? Should not this be named `alistAllKeys'?
@@ -156,7 +156,7 @@ ASSOCRIGHT x ==
ADDASSOC: (%Thing,%Thing,%List) -> %List
ADDASSOC(x,y,l) ==
atom l => [[x,:y],:l]
- x = first first l => [[x,:y],:cdr l]
+ x = first first l => [[x,:y],:rest l]
[first l,:ADDASSOC(x,y,rest l)]