Artifact d4cc40e1307f8f9d1527be31068acdf302d77bc11b587464672e9ce171ca3057:
- File
psl-1983/3-1/util/misc-macros.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: 1300) [annotate] [blame] [check-ins using] [more...]
- File
psl-1983/util/misc-macros.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: 1300) [annotate] [blame] [check-ins using]
% MISC-MACROS.SL - assorted useful macros % % Author: Don Morrison % Symbolic Computation Group % Computer Science Dept. % University of Utah % Date: Wednesday, 12 May 1982 % Copyright (c) 1981 University of Utah (defmacro funcall u `(apply ,(car u) (list ,@(cdr u)))) (copyd 'call 'funcall) (defmacro eqfirst (u v) `(eqcar ,u ,v)) (defmacro bldid (s . args) `(intern (bldmsg ,s ,@args))) (defmacro nary-concat u (expand u 'concat)) (defmacro-no-displace defstub (name . rst) % quick, kludgy hack -- should be much better (let ((args (if (pairp rst) (pop rst)))) `(de ,name ,args (stub-print ',name ',args (list ,@args)) ,@rst (let ((*ContinuableError t)) (break))))) (de stub-print (name arg-names actual-args) (errorprintf "Stub %w called with arguments:" name) (for (in u arg-names) (in v actual-args) (do (errorprintf " %w: %p%n" u v))) (terpri)) (defmacro circular-list L `(let ((***CIRCULAR-LIST-ARG*** (list ,@L))) (nconc ***CIRCULAR-LIST-ARG*** ***CIRCULAR-LIST-ARG***))) (defmacro nothing U nil) % Nary no-op returning nil; args not evaluated. (defmacro make-list (N . rst) `(make-list-1 ,N ,(if (pairp rst) (car rst) nil))) (de make-list-1 (N init) (for (from i 1 N) (collect init)))