aboutsummaryrefslogtreecommitdiff
path: root/src/interp
diff options
context:
space:
mode:
authordos-reis <gdr@axiomatics.org>2010-06-01 21:25:59 +0000
committerdos-reis <gdr@axiomatics.org>2010-06-01 21:25:59 +0000
commit50cfb5533a31afb7d85c0574ab6359efbc4f164e (patch)
treeb36df56535dc0f46d1104a98e4bc8046baf1e439 /src/interp
parent39f3846ba6690deb71bb26630fbd655fabf36ebd (diff)
downloadopen-axiom-50cfb5533a31afb7d85c0574ab6359efbc4f164e.tar.gz
* algebra/list.spad.pamphlet: Use builtin functions.
Diffstat (limited to 'src/interp')
-rw-r--r--src/interp/g-opt.boot5
-rw-r--r--src/interp/g-util.boot21
2 files changed, 15 insertions, 11 deletions
diff --git a/src/interp/g-opt.boot b/src/interp/g-opt.boot
index eccf8e73..a582c8a2 100644
--- a/src/interp/g-opt.boot
+++ b/src/interp/g-opt.boot
@@ -407,12 +407,13 @@ $VMsideEffectFreeOperators ==
%imul %iadd %isub %igcd %ilcm %ipow %imin %imax %ieven? %iodd? %iinc
%feq %flt %fle %fgt %fge %fmul %fadd %fsub %fexp %fmin %fmax %float?
%fpow %nil %pair? %lconcat %llength %lfirst %lsecond %lthird
- %hash %ismall? %string? %ceq %clt %cle %cgt %cge %c2i %i2c)
+ %lreverse %lempty? %hash %ismall? %string?
+ %ceq %clt %cle %cgt %cge %c2i %i2c)
++ List of simple VM operators
$simpleVMoperators ==
append($VMsideEffectFreeOperators,
- ["CONS","LIST","VECTOR","STRINGIMAGE",'%gensym,
+ ["CONS","LIST","VECTOR","STRINGIMAGE",'%gensym, '%lreverse_!,
"MAKE-FULL-CVEC","BVEC-MAKE-FULL","COND"])
++ Return true if the `form' is semi-simple with respect to
diff --git a/src/interp/g-util.boot b/src/interp/g-util.boot
index a3674a01..d949a6fb 100644
--- a/src/interp/g-util.boot
+++ b/src/interp/g-util.boot
@@ -299,16 +299,19 @@ for x in [
-- list contants
-- ['%nil, :'NIL],
-- unary list operations
- ['%head, :'CAR],
- ['%makepair,:'CONS],
- ['%lfirst, :'CAR],
- ['%llength, :'LIST_-LENGTH],
- ['%lsecond, :'CADR],
- ['%lthird, :'CADDR],
- ['%pair?, :'CONSP],
- ['%tail, :'CDR],
+ ['%head, :'CAR],
+ ['%makepair, :'CONS],
+ ['%lempty?, :'NULL],
+ ['%lfirst, :'CAR],
+ ['%llength, :'LIST_-LENGTH],
+ ['%lreverse, :'REVERSE],
+ ['%lreverse_!,:'NREVERSE],
+ ['%lsecond, :'CADR],
+ ['%lthird, :'CADDR],
+ ['%pair?, :'CONSP],
+ ['%tail, :'CDR],
-- binary list operations
- ['%lconcat, :'APPEND],
+ ['%lconcat, :'APPEND],
-- symbol unary functions
['%gensym, :'GENSYM],