X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=flower%2Fmatrix-debug.cc;h=82080f2a6d8a560930ba15498a5ef22c4bbc99d1;hb=69b9cead5afe7164b9053d26eba582fec3825ef8;hp=099a05beb9351fc2ef915fb903531313a7fc2aff;hpb=6dc4e4d14a67f65f337ec1a06466e748c68dcad5;p=lilypond.git diff --git a/flower/matrix-debug.cc b/flower/matrix-debug.cc index 099a05beb9..82080f2a6d 100644 --- a/flower/matrix-debug.cc +++ b/flower/matrix-debug.cc @@ -3,30 +3,30 @@ source file of the Flower Library - (c) 1997 Han-Wen Nienhuys + (c) 1997--1998 Han-Wen Nienhuys */ #include "flower-debug.hh" #include "matrix.hh" -#include "matrix-storage.hh" - Matrix::operator String() const { - String s; + String s; #ifndef NPRINT - Matrix_storage const * stor_c_l = dat; - s=String("matrix { (") + dat->name() + ")\n"; - for (int i=0; i< rows(); i++){ - for (int j = 0; j < cols(); j++) { - s+= String(stor_c_l->elem(i,j), "%6f "); + Full_storage const * stor_c_l = dat_; + s=String ("matrix {"); + for (int i=0; i< rows(); i++) + { + for (int j = 0; j < cols(); j++) + { + s+= String (stor_c_l->elem (i,j), "%6f "); } - s+="\n"; + s+="\n"; } - s+="}\n"; + s+="}\n"; #endif - return s; + return s; } @@ -34,21 +34,22 @@ void Matrix::print() const { #ifndef NPRINT - fdebug << *this; + fdebug << *this; #endif } Vector::operator String() const { - String s; + String s; #ifndef NPRINT - s="vector ["; - for (int i=0; i < dim(); i++) { - s += String(dat[i], "%6f") + String(' '); + s=String ("vector (") + dim () + ") ["; + for (int i=0; i < dim(); i++) + { + s += String (dat[i], "%6f") + String (' '); } - s+="]"; + s+="]\n"; #endif - return s; + return s; } @@ -56,6 +57,6 @@ void Vector::print() const { #ifndef NDEBUG - fdebug << *this<<'\n'; + fdebug << *this<<'\n'; #endif }