From 96e276a68a67cbf947fb83b35e899c9c351a6703 Mon Sep 17 00:00:00 2001 From: Tim Daly Date: Sun, 26 Apr 2015 02:41:35 -0400 Subject: [PATCH] books/bookvol5 move/collect/reorder algebra support code The Common Lisp Algebra Support chapter contains functions which are used in the algebra. These were collected and reordered by domain. --- books/bookvol5.pamphlet | 40 +++++++++++++++++++++++++++++++------- changelog | 2 + patch | 3 +- src/axiom-website/patches.html | 2 + src/interp/vmlisp.lisp.pamphlet | 9 -------- 5 files changed, 37 insertions(+), 19 deletions(-) diff --git a/books/bookvol5.pamphlet b/books/bookvol5.pamphlet index dcb6d1c..019ddbf 100644 --- a/books/bookvol5.pamphlet +++ b/books/bookvol5.pamphlet @@ -45519,14 +45519,6 @@ Note that this assumes ``table'' is a string. \end{chunk} -\defun{qenum}{qenum} -\tpdhere{This is also used in bookvol10.3 in the CHAR domain. Fix this.} -\begin{chunk}{defun qenum 0} -(defun qenum (cvec ind) - (char-code (char cvec ind))) - -\end{chunk} - \defmacro{identp} \begin{chunk}{defmacro identp 0} (defmacro identp (x) @@ -46760,6 +46752,34 @@ For example, ``/'' ``/u/smwatt'' ``../src'' \end{chunk} +\section{IndexedString} + +\defun{qenum}{qenum} +This is also used in bookvol10.3 in the CHAR domain. +\begin{chunk}{defun qenum 0} +(defun qenum (cvec ind) + (char-code (char cvec ind))) + +\end{chunk} + +\begin{chunk}{defmacro qcsize 0} +(defmacro qcsize (x) + `(the fixnum (length (the simple-string ,x)))) + +\end{chunk} + +\begin{chunk}{defun qeset 0} +(defun qeset (cvec ind charnum) + (setf (char cvec ind) (code-char charnum))) + +\end{chunk} + +\begin{chunk}{defmacro qsgreaterp 0} +(defmacro qsgreaterp (a b) + `(> (the fixnum ,a) (the fixnum ,b))) + +\end{chunk} + \section{InputForm} \defun{mkobjFn}{called by interpret function} @@ -46992,6 +47012,7 @@ It is used in the {\tt myTrap} local function in Plot3d. \end{chunk} \defmacro{qslessp} +This is also used in IndexedString \begin{chunk}{defmacro qslessp 0} (defmacro qslessp (a b) `(< (the fixnum ,a) (the fixnum ,b))) @@ -59923,9 +59944,11 @@ digits in TechExplorer. Since Saturn is gone we can remove it. \getchunk{defmacro getMsgTag 0} \getchunk{defmacro getMsgTag? 0} \getchunk{defmacro getMsgText 0} +\getchunk{defmacro qcsize 0} \getchunk{defmacro qsabsval 0} \getchunk{defmacro qsadd1 0} \getchunk{defmacro qsdifference 0} +\getchunk{defmacro qsgreaterp 0} \getchunk{defmacro qslessp 0} \getchunk{defmacro qsmax 0} \getchunk{defmacro qsmin 0} @@ -60296,6 +60319,7 @@ digits in TechExplorer. Since Saturn is gone we can remove it. \getchunk{defun pname 0} \getchunk{defun qenum 0} +\getchunk{defun qeset 0} \getchunk{defun qsquotient 0} \getchunk{defun qsremainder 0} \getchunk{defun quotient2 0} diff --git a/changelog b/changelog index cd06cd8..f6e5ac2 100644 --- a/changelog +++ b/changelog @@ -1,3 +1,5 @@ +20150425 tpd src/axiom-website/patches.html 20150425.02.tpd.patch +20150425 tpd src/interp/vmlisp.lisp move/collect/reorder algebra support code 20150425 tpd src/axiom-website/patches.html 20150425.01.tpd.patch 20150425 tpd src/interp/vmlisp.lisp move/collect/reorder algebra support code 20150425 tpd books/bookvol9 move/collect/reorder algebra support code diff --git a/patch b/patch index c47e8e8..638a197 100644 --- a/patch +++ b/patch @@ -1,6 +1,5 @@ books/bookvol5 move/collect/reorder algebra support code The Common Lisp Algebra Support chapter contains functions which -are used in the algebra. These were collected and reordered by -domain. +are used in the algebra. These were collected and reordered by domain. diff --git a/src/axiom-website/patches.html b/src/axiom-website/patches.html index b24d44b..53c6137 100644 --- a/src/axiom-website/patches.html +++ b/src/axiom-website/patches.html @@ -5036,6 +5036,8 @@ src/interp/vmlisp.lisp remove dead code, )zsys support code
books/bookvol5 add )license command
20150425.01.tpd.patch books/bookvol5 move/collect/reorder algebra support code
+20150425.02.tpd.patch +books/bookvol5 move/collect/reorder algebra support code
diff --git a/src/interp/vmlisp.lisp.pamphlet b/src/interp/vmlisp.lisp.pamphlet index 16934c5..3810d12 100644 --- a/src/interp/vmlisp.lisp.pamphlet +++ b/src/interp/vmlisp.lisp.pamphlet @@ -266,9 +266,6 @@ documentclass{article} (defmacro qcddddr (x) `(cdr (the cons (cdr (the cons (cdr (the cons (cdr (the cons ,x))))))))) -(defmacro qcsize (x) - `(the fixnum (length (the simple-string ,x)))) - (defmacro qlength (a) `(length ,a)) @@ -302,9 +299,6 @@ documentclass{article} (defmacro qsetvelt-1 (vec ind val) `(setf (svref ,vec (the fixnum (1- (the fixnum ,ind)))) ,val)) -(defmacro qsgreaterp (a b) - `(> (the fixnum ,a) (the fixnum ,b))) - (defmacro qsinc1 (x) `(the fixnum (1+ (the fixnum ,x)))) @@ -727,9 +721,6 @@ can be restored. ; 17.2 Accessing -(defun QESET (cvec ind charnum) - (setf (char cvec ind) (code-char charnum))) - (defun string2id-n (cvec sint) (if (< sint 1) nil -- 1.7.5.4