From bc4d6f19e9b758aa61d1d6544e644342f7b193e9 Mon Sep 17 00:00:00 2001 From: Kris Katterjohn Date: Mon, 3 Jan 2022 13:32:23 -0500 Subject: [PATCH] Fix the bogus MFEXPR* property for MPOIS The MFEXPR* prop for MPOIS has been the list (LAMBDA (X) X) instead of the desired identity function. Attempting to apply this list to args would cause a lisp error. Here's one way to trigger the bug: (%i1) define (foo (), intopois (1))$ (%i2) foo (); This used to work in Macsyma under Maclisp and some other older lisp dialects. This bogus definition for the MFEXPR* prop for MPOIS is in pois3. It turns out that a valid definition for this is in pois2. Given the way that Maxima is being built, the definition from pois2 is being replaced by the one in pois3. I'm removing the definition from pois3, and moving the definition from pois2 to pois3. The move is just because there is already a comment in pois3 about this property. No problems with the test suite or share test suite. --- src/pois2.lisp | 2 -- src/pois3.lisp | 2 +- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/src/pois2.lisp b/src/pois2.lisp index b6fb86e94..9ed87af7a 100644 --- a/src/pois2.lisp +++ b/src/pois2.lisp @@ -14,8 +14,6 @@ (declare-top (special poisvals poishift poistsm poissiz poists $poisz $pois1)) -(defmspec mpois (x) x) - (defun poislim1 (uu n) (declare (ignore uu)) (unless (fixnump n) diff --git a/src/pois3.lisp b/src/pois3.lisp index 4b110ffe9..e03f60ee3 100644 --- a/src/pois3.lisp +++ b/src/pois3.lisp @@ -89,7 +89,7 @@ ;;; THIS TELLS THE EVALUATOR TO KEEP OUT OF POISSON $SERIES. -(defprop mpois (lambda (x) x) mfexpr*) +(defmspec mpois (x) x) (defmfun $poisplus (a b) (setq a (intopois a) b (intopois b)) -- 2.11.4.GIT