Artifact 0d5025f39e8de0035ecca5c806551ea7cb873f47749e5204e234e9e5190dd48b:
- File
psl-1983/3-1/util/slow-vectors.sl
— part of check-in
[eb17ceb7f6]
at
2020-04-21 19:40:01
on branch master
— Add Reduce 3.0 to the historical section of the archive, and some more
files relating to version sof PSL from the early 1980s. Thanks are due to
Paul McJones and Nelson Beebe for these, as well as to all the original
authors.git-svn-id: https://svn.code.sf.net/p/reduce-algebra/code/historical@5328 2bfe0521-f11c-4a00-b80e-6202646ff360 (user: arthurcnorman@users.sourceforge.net, size: 1216) [annotate] [blame] [check-ins using] [more...]
- File
psl-1983/util/slow-vectors.sl
— part of check-in
[eb17ceb7f6]
at
2020-04-21 19:40:01
on branch master
— Add Reduce 3.0 to the historical section of the archive, and some more
files relating to version sof PSL from the early 1980s. Thanks are due to
Paul McJones and Nelson Beebe for these, as well as to all the original
authors.git-svn-id: https://svn.code.sf.net/p/reduce-algebra/code/historical@5328 2bfe0521-f11c-4a00-b80e-6202646ff360 (user: arthurcnorman@users.sourceforge.net, size: 1216) [annotate] [blame] [check-ins using]
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % SLOW-VECTORS - Useful Vector Functions (with lots of error checking) % % Author: Alan Snyder % Hewlett-Packard/CRC % Date: 17 September 1982 % % Defines the following functions: % % (vector-fetch v i) % (vector-store v i x) % (vector-size v) % (vector-upper-bound v) % (vector-empty? v) % % See FAST-VECTORS for faster (unchecked) compiled versions of these functions. % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% (de vector-fetch (v i) (cond ((not (Vectorp v)) (NonVectorError v 'Vector-Fetch)) ((not (FixP i)) (NonIntegerError i 'Vector-Fetch)) (t (indx v i)) )) (de vector-store (v i x) (cond ((not (Vectorp v)) (NonVectorError v 'Vector-Store)) ((not (FixP i)) (NonIntegerError i 'Vector-Store)) (t (setindx v i x)) )) (de vector-size (v) (cond ((not (Vectorp v)) (NonVectorError v 'Vector-Size)) (t (Plus2 (size v) 1)) )) (de vector-upper-bound (v) (cond ((not (Vectorp v)) (NonVectorError v 'Vector-Upper-Bound)) (t (size v)) )) (de vector-empty? (v) (cond ((not (Vectorp v)) (NonVectorError v 'Vector-Empty?)) (t (EqN (size v) -1)) ))