From: Dieter K. <cra...@us...> - 2011-08-14 18:00:06
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Maxima, A Computer Algebra System". The branch, master has been updated via d139d678e0e25f7b155182741e8407f32f5dff68 (commit) via f1755df2c49be03e22be3b41f2349456a66013de (commit) from c8d7c31723401fac9dabe56b4f4f9f99d96e7a9b (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit d139d678e0e25f7b155182741e8407f32f5dff68 Author: crategus <cra...@us...> Date: Sun Aug 14 19:55:16 2011 +0200 Checking more careful in dim-$matrix, that the matrix is well formed. Related bug report: ID: 3390551 Error break in rtest2 with display_all=true diff --git a/src/displa.lisp b/src/displa.lisp index ac67a08..c1e73ec 100644 --- a/src/displa.lisp +++ b/src/displa.lisp @@ -1016,11 +1016,18 @@ (displa-def $matrix dim-$matrix) (defun dim-$matrix (form result) - (prog (dmstr rstr cstr consp) + (prog (dmstr rstr cstr consp cols) + (setq cols (if ($listp (cadr form)) (length (cadr form)) 0)) (if (or (null (cdr form)) - (memalike '((mlist simp)) (cdr form)) - (dolist (row (cdr form)) (if (not ($listp row)) (return t)))) - (return (dimension-function form result))) + (memalike '((mlist simp)) (cdr form)) + ;; Check if the matrix has lists as rows with a equal number of + ;; columns. + (dolist (row (cdr form)) + (if (or (not ($listp row)) + (not (eql cols (length row)))) + (return t)))) + ;; The matrix is not well formed. Display the matrix in linear mode. + (return (dimension-function form result))) (do ((l (cdadr form) (cdr l))) ((null l)) (setq dmstr (cons nil dmstr) cstr (cons 0 cstr))) (do ((r (cdr form) (cdr r)) (h1 0) (d1 0)) commit f1755df2c49be03e22be3b41f2349456a66013de Author: crategus <cra...@us...> Date: Sun Aug 14 19:50:24 2011 +0200 Saving the value of the option variable display2d display2d is a resetable option variable. We save the value of display2d and restore it after the reset. This allows to run the testsuite completely in both display modes. Changes files: rtest3.mac rtest16.mac diff --git a/tests/rtest16.mac b/tests/rtest16.mac index d61dc0f..bc0cb9a 100644 --- a/tests/rtest16.mac +++ b/tests/rtest16.mac @@ -1,9 +1,18 @@ (kill (all), values); []; -/* make sure things work after a reset(). ID: 1986726 and ID: 2787047 */ +/* make sure things work after a reset(). ID: 1986726 and ID: 2787047 + * + * display2d is a resetable option variable. We save the value of display2d + * and restore it after the reset. This allows to run the testsuite in both + * display modes. + */ +(save:display2d, done); +done$ (reset(),0); 0; +(display2d:save, done); +done$ /* Tests from Bug 1036900 */ /* These bugs were fixed in limit.lisp rev 1.7, 2004/10/04 */ diff --git a/tests/rtest3.mac b/tests/rtest3.mac index 39e3bda..a29e252 100644 --- a/tests/rtest3.mac +++ b/tests/rtest3.mac @@ -328,10 +328,18 @@ block ([L : [], s : +2], for i:1 thru 10 step s do L : cons (s : -s, L), L); block ([L : [], s : -2], for i:10 thru 1 step s do L : cons (s : -s, L), L); [2, -2, 2, -2, 2]; -/* bug reported to mailing list 2009-05-13 "reset ( radexpand, domain )" */ - +/* bug reported to mailing list 2009-05-13 "reset ( radexpand, domain )" + * + * display2d is a resetable option variable. We save the value of display2d + * and restore it after the reset. This allows to run the testsuite in both + * display modes. + */ +(save:display2d, done); +done$ (reset (), [radexpand, domain]); [true, real]; +(display2d:save, done); +done$ [radexpand, domain] : [all, complex]; [all, complex]; ----------------------------------------------------------------------- Summary of changes: src/displa.lisp | 15 +++++++++++---- tests/rtest16.mac | 11 ++++++++++- tests/rtest3.mac | 12 ++++++++++-- 3 files changed, 31 insertions(+), 7 deletions(-) hooks/post-receive -- Maxima, A Computer Algebra System |