# HG changeset patch # User jwe # Date 797135753 0 # Node ID 0bf4d2b7def4f4e2c71aa65eb905255ba8ecd379 # Parent 9689615b34f2b68b721bdba6e5072d395df95f89 [project @ 1995-04-06 02:33:59 by jwe] diff -r 9689615b34f2 -r 0bf4d2b7def4 liboctave/CColVector.cc --- a/liboctave/CColVector.cc Thu Apr 06 02:25:28 1995 +0000 +++ b/liboctave/CColVector.cc Thu Apr 06 02:35:53 1995 +0000 @@ -48,16 +48,8 @@ * Complex Column Vector class */ -#define KLUDGE_VECTORS -#define TYPE Complex -#define KL_VEC_TYPE ComplexColumnVector -#include "mx-kludge.cc" -#undef KLUDGE_VECTORS -#undef TYPE -#undef KL_VEC_TYPE - ComplexColumnVector::ComplexColumnVector (const ColumnVector& a) - : Array (a.length ()) + : MArray (a.length ()) { for (int i = 0; i < length (); i++) elem (i) = a.elem (i); diff -r 9689615b34f2 -r 0bf4d2b7def4 liboctave/CColVector.h --- a/liboctave/CColVector.h Thu Apr 06 02:25:28 1995 +0000 +++ b/liboctave/CColVector.h Thu Apr 06 02:35:53 1995 +0000 @@ -24,34 +24,32 @@ #if !defined (octave_ComplexColumnVector_h) #define octave_ComplexColumnVector_h 1 -#include "Array.h" +#include "MArray.h" #include "mx-defs.h" extern "C++" { -class ComplexColumnVector : public Array +class ComplexColumnVector : public MArray { friend class ComplexMatrix; friend class ComplexRowVector; public: - ComplexColumnVector (void) : Array () { } - ComplexColumnVector (int n) : Array (n) { } - ComplexColumnVector (int n, const Complex& val) : Array (n, val) { } + ComplexColumnVector (void) : MArray () { } + ComplexColumnVector (int n) : MArray (n) { } + ComplexColumnVector (int n, const Complex& val) : MArray (n, val) { } ComplexColumnVector (const ColumnVector& a); - ComplexColumnVector (const Array& a) : Array (a) { } - ComplexColumnVector (const ComplexColumnVector& a) : Array (a) { } + ComplexColumnVector (const MArray& a) : MArray (a) { } + ComplexColumnVector (const ComplexColumnVector& a) : MArray (a) { } ComplexColumnVector& operator = (const ComplexColumnVector& a) { - Array::operator = (a); + MArray::operator = (a); return *this; } -// operator Array& () const { return *this; } - int operator == (const ComplexColumnVector& a) const; int operator != (const ComplexColumnVector& a) const; @@ -184,17 +182,9 @@ friend ostream& operator << (ostream& os, const ComplexColumnVector& a); friend istream& operator >> (istream& is, ComplexColumnVector& a); -#define KLUDGE_VECTORS -#define TYPE Complex -#define KL_VEC_TYPE ComplexColumnVector -#include "mx-kludge.h" -#undef KLUDGE_VECTORS -#undef TYPE -#undef KL_VEC_TYPE - private: - ComplexColumnVector (Complex *d, int l) : Array (d, l) { } + ComplexColumnVector (Complex *d, int l) : MArray (d, l) { } }; } // extern "C++" diff -r 9689615b34f2 -r 0bf4d2b7def4 liboctave/CDiagMatrix.cc --- a/liboctave/CDiagMatrix.cc Thu Apr 06 02:25:28 1995 +0000 +++ b/liboctave/CDiagMatrix.cc Thu Apr 06 02:35:53 1995 +0000 @@ -37,30 +37,22 @@ * Complex Diagonal Matrix class */ -#define KLUDGE_DIAG_MATRICES -#define TYPE Complex -#define KL_DMAT_TYPE ComplexDiagMatrix -#include "mx-kludge.cc" -#undef KLUDGE_DIAG_MATRICES -#undef TYPE -#undef KL_DMAT_TYPE - ComplexDiagMatrix::ComplexDiagMatrix (const RowVector& a) - : DiagArray (a.length ()) + : MDiagArray (a.length ()) { for (int i = 0; i < length (); i++) elem (i, i) = a.elem (i); } ComplexDiagMatrix::ComplexDiagMatrix (const ColumnVector& a) - : DiagArray (a.length ()) + : MDiagArray (a.length ()) { for (int i = 0; i < length (); i++) elem (i, i) = a.elem (i); } ComplexDiagMatrix::ComplexDiagMatrix (const DiagMatrix& a) - : DiagArray (a.rows (), a.cols ()) + : MDiagArray (a.rows (), a.cols ()) { for (int i = 0; i < length (); i++) elem (i, i) = a.elem (i, i); diff -r 9689615b34f2 -r 0bf4d2b7def4 liboctave/CDiagMatrix.h --- a/liboctave/CDiagMatrix.h Thu Apr 06 02:25:28 1995 +0000 +++ b/liboctave/CDiagMatrix.h Thu Apr 06 02:35:53 1995 +0000 @@ -24,7 +24,7 @@ #if !defined (octave_ComplexDiagMatrix_h) #define octave_ComplexDiagMatrix_h 1 -#include "Array.h" +#include "MArray.h" #include "dRowVector.h" #include "CRowVector.h" @@ -35,30 +35,30 @@ extern "C++" { -class ComplexDiagMatrix : public DiagArray +class ComplexDiagMatrix : public MDiagArray { public: - ComplexDiagMatrix (void) : DiagArray () { } - ComplexDiagMatrix (int n) : DiagArray (n) { } + ComplexDiagMatrix (void) : MDiagArray () { } + ComplexDiagMatrix (int n) : MDiagArray (n) { } ComplexDiagMatrix (int n, const Complex& val) - : DiagArray (n, val) { } - ComplexDiagMatrix (int r, int c) : DiagArray (r, c) { } + : MDiagArray (n, val) { } + ComplexDiagMatrix (int r, int c) : MDiagArray (r, c) { } ComplexDiagMatrix (int r, int c, const Complex& val) - : DiagArray (r, c, val) { } + : MDiagArray (r, c, val) { } ComplexDiagMatrix (const RowVector& a); - ComplexDiagMatrix (const ComplexRowVector& a) : DiagArray (a) { } + ComplexDiagMatrix (const ComplexRowVector& a) : MDiagArray (a) { } ComplexDiagMatrix (const ColumnVector& a); ComplexDiagMatrix (const ComplexColumnVector& a) - : DiagArray (a) { } + : MDiagArray (a) { } ComplexDiagMatrix (const DiagMatrix& a); - ComplexDiagMatrix (const DiagArray& a) - : DiagArray (a) { } - ComplexDiagMatrix (const ComplexDiagMatrix& a) : DiagArray (a) { } + ComplexDiagMatrix (const MDiagArray& a) + : MDiagArray (a) { } + ComplexDiagMatrix (const ComplexDiagMatrix& a) : MDiagArray (a) { } ComplexDiagMatrix& operator = (const ComplexDiagMatrix& a) { - DiagArray::operator = (a); + MDiagArray::operator = (a); return *this; } @@ -154,18 +154,10 @@ friend ostream& operator << (ostream& os, const ComplexDiagMatrix& a); -#define KLUDGE_DIAG_MATRICES -#define TYPE Complex -#define KL_DMAT_TYPE ComplexDiagMatrix -#include "mx-kludge.h" -#undef KLUDGE_DIAG_MATRICES -#undef TYPE -#undef KL_DMAT_TYPE - private: ComplexDiagMatrix (Complex *d, int nr, int nc) - : DiagArray (d, nr, nc) { } + : MDiagArray (d, nr, nc) { } }; } // extern "C++" diff -r 9689615b34f2 -r 0bf4d2b7def4 liboctave/CMatrix.cc --- a/liboctave/CMatrix.cc Thu Apr 06 02:25:28 1995 +0000 +++ b/liboctave/CMatrix.cc Thu Apr 06 02:35:53 1995 +0000 @@ -74,20 +74,12 @@ int F77_FCN (cfftb) (const int*, Complex*, Complex*); } -#define KLUDGE_MATRICES -#define TYPE Complex -#define KL_MAT_TYPE ComplexMatrix -#include "mx-kludge.cc" -#undef KLUDGE_MATRICES -#undef TYPE -#undef KL_MAT_TYPE - /* * Complex Matrix class */ ComplexMatrix::ComplexMatrix (const Matrix& a) - : Array2 (a.rows (), a.cols ()) + : MArray2 (a.rows (), a.cols ()) { for (int j = 0; j < cols (); j++) for (int i = 0; i < rows (); i++) @@ -95,14 +87,14 @@ } ComplexMatrix::ComplexMatrix (const DiagMatrix& a) - : Array2 (a.rows (), a.cols (), 0.0) + : MArray2 (a.rows (), a.cols (), 0.0) { for (int i = 0; i < a.length (); i++) elem (i, i) = a.elem (i, i); } ComplexMatrix::ComplexMatrix (const ComplexDiagMatrix& a) - : Array2 (a.rows (), a.cols (), 0.0) + : MArray2 (a.rows (), a.cols (), 0.0) { for (int i = 0; i < a.length (); i++) elem (i, i) = a.elem (i, i); diff -r 9689615b34f2 -r 0bf4d2b7def4 liboctave/CMatrix.h --- a/liboctave/CMatrix.h Thu Apr 06 02:25:28 1995 +0000 +++ b/liboctave/CMatrix.h Thu Apr 06 02:35:53 1995 +0000 @@ -26,13 +26,13 @@ #include -#include "Array.h" +#include "MArray.h" #include "mx-defs.h" extern "C++" { -class ComplexMatrix : public Array2 +class ComplexMatrix : public MArray2 { friend class Matrix; friend class ComplexCHOL; @@ -45,20 +45,20 @@ public: - ComplexMatrix (void) : Array2 () { } - ComplexMatrix (int r, int c) : Array2 (r, c) { } + ComplexMatrix (void) : MArray2 () { } + ComplexMatrix (int r, int c) : MArray2 (r, c) { } ComplexMatrix (int r, int c, const Complex& val) - : Array2 (r, c, val) { } + : MArray2 (r, c, val) { } ComplexMatrix (const Matrix& a); - ComplexMatrix (const Array2& a) : Array2 (a) { } - ComplexMatrix (const ComplexMatrix& a) : Array2 (a) { } + ComplexMatrix (const MArray2& a) : MArray2 (a) { } + ComplexMatrix (const ComplexMatrix& a) : MArray2 (a) { } ComplexMatrix (const DiagMatrix& a); - ComplexMatrix (const DiagArray& a) : Array2 (a) { } + ComplexMatrix (const MDiagArray& a) : MArray2 (a) { } ComplexMatrix (const ComplexDiagMatrix& a); ComplexMatrix& operator = (const ComplexMatrix& a) { - Array2::operator = (a); + MArray2::operator = (a); return *this; } @@ -340,17 +340,9 @@ friend ostream& operator << (ostream& os, const ComplexMatrix& a); friend istream& operator >> (istream& is, ComplexMatrix& a); -#define KLUDGE_MATRICES -#define TYPE Complex -#define KL_MAT_TYPE ComplexMatrix -#include "mx-kludge.h" -#undef KLUDGE_MATRICES -#undef TYPE -#undef KL_MAT_TYPE - private: - ComplexMatrix (Complex *d, int r, int c) : Array2 (d, r, c) { } + ComplexMatrix (Complex *d, int r, int c) : MArray2 (d, r, c) { } }; } // extern "C++" diff -r 9689615b34f2 -r 0bf4d2b7def4 liboctave/CRowVector.cc --- a/liboctave/CRowVector.cc Thu Apr 06 02:25:28 1995 +0000 +++ b/liboctave/CRowVector.cc Thu Apr 06 02:35:53 1995 +0000 @@ -48,16 +48,8 @@ * Complex Row Vector class */ -#define KLUDGE_VECTORS -#define TYPE Complex -#define KL_VEC_TYPE ComplexRowVector -#include "mx-kludge.cc" -#undef KLUDGE_VECTORS -#undef TYPE -#undef KL_VEC_TYPE - ComplexRowVector::ComplexRowVector (const RowVector& a) - : Array (a.length ()) + : MArray (a.length ()) { for (int i = 0; i < length (); i++) elem (i) = a.elem (i); diff -r 9689615b34f2 -r 0bf4d2b7def4 liboctave/CRowVector.h --- a/liboctave/CRowVector.h Thu Apr 06 02:25:28 1995 +0000 +++ b/liboctave/CRowVector.h Thu Apr 06 02:35:53 1995 +0000 @@ -24,28 +24,28 @@ #if !defined (octave_ComplexRowVector_h) #define octave_ComplexRowVector_h 1 -#include "Array.h" +#include "MArray.h" #include "mx-defs.h" extern "C++" { -class ComplexRowVector : public Array +class ComplexRowVector : public MArray { friend class ComplexColumnVector; public: - ComplexRowVector (void) : Array () { } - ComplexRowVector (int n) : Array (n) { } - ComplexRowVector (int n, const Complex& val) : Array (n, val) { } + ComplexRowVector (void) : MArray () { } + ComplexRowVector (int n) : MArray (n) { } + ComplexRowVector (int n, const Complex& val) : MArray (n, val) { } ComplexRowVector (const RowVector& a); - ComplexRowVector (const Array& a) : Array (a) { } - ComplexRowVector (const ComplexRowVector& a) : Array (a) { } + ComplexRowVector (const MArray& a) : MArray (a) { } + ComplexRowVector (const ComplexRowVector& a) : MArray (a) { } ComplexRowVector& operator = (const ComplexRowVector& a) { - Array::operator = (a); + MArray::operator = (a); return *this; } @@ -149,17 +149,9 @@ friend ostream& operator << (ostream& os, const ComplexRowVector& a); friend istream& operator >> (istream& is, ComplexRowVector& a); -#define KLUDGE_VECTORS -#define TYPE Complex -#define KL_VEC_TYPE ComplexRowVector -#include "mx-kludge.h" -#undef KLUDGE_VECTORS -#undef TYPE -#undef KL_VEC_TYPE - private: - ComplexRowVector (Complex *d, int l) : Array (d, l) { } + ComplexRowVector (Complex *d, int l) : MArray (d, l) { } }; // row vector by column vector -> scalar diff -r 9689615b34f2 -r 0bf4d2b7def4 liboctave/Makefile.in --- a/liboctave/Makefile.in Thu Apr 06 02:25:28 1995 +0000 +++ b/liboctave/Makefile.in Thu Apr 06 02:35:53 1995 +0000 @@ -19,7 +19,7 @@ INSTALL_DATA = @INSTALL_DATA@ MATRIX_INC = Array.h MArray.h Matrix.h mx-base.h mx-defs.h mx-ext.h \ - mx-kludge.h CColVector.h CDiagMatrix.h CMatrix.h CRowVector.h \ + CColVector.h CDiagMatrix.h CMatrix.h CRowVector.h \ CmplxAEPBAL.h CmplxCHOL.h CmplxDET.h CmplxHESS.h CmplxLU.h \ CmplxQR.h CmplxQRP.h CmplxSCHUR.h CmplxSVD.h EIG.h \ dColVector.h dDiagMatrix.h dMatrix.h dRowVector.h dbleAEPBAL.h \ @@ -49,7 +49,7 @@ Quad.cc Range.cc lo-error.cc sun-utils.cc $(TEMPLATE_SRC) \ $(TI_SRC) $(MATRIX_SRC) -EXTRAS = mx-kludge.cc mx-inlines.cc +EXTRAS = mx-inlines.cc DISTFILES = Makefile.in $(SOURCES) $(INCLUDES) $(EXTRAS) diff -r 9689615b34f2 -r 0bf4d2b7def4 liboctave/dColVector.cc --- a/liboctave/dColVector.cc Thu Apr 06 02:25:28 1995 +0000 +++ b/liboctave/dColVector.cc Thu Apr 06 02:35:53 1995 +0000 @@ -48,14 +48,6 @@ * Column Vector class. */ -#define KLUDGE_VECTORS -#define TYPE double -#define KL_VEC_TYPE ColumnVector -#include "mx-kludge.cc" -#undef KLUDGE_VECTORS -#undef TYPE -#undef KL_VEC_TYPE - int ColumnVector::operator == (const ColumnVector& a) const { diff -r 9689615b34f2 -r 0bf4d2b7def4 liboctave/dColVector.h --- a/liboctave/dColVector.h Thu Apr 06 02:25:28 1995 +0000 +++ b/liboctave/dColVector.h Thu Apr 06 02:35:53 1995 +0000 @@ -24,28 +24,28 @@ #if !defined (octave_ColumnVector_h) #define octave_ColumnVector_h 1 -#include "Array.h" +#include "MArray.h" #include "mx-defs.h" extern "C++" { -class ColumnVector : public Array +class ColumnVector : public MArray { friend class Matrix; friend class RowVector; public: - ColumnVector (void) : Array () { } - ColumnVector (int n) : Array (n) { } - ColumnVector (int n, double val) : Array (n, val) { } - ColumnVector (const Array& a) : Array (a) { } - ColumnVector (const ColumnVector& a) : Array (a) { } + ColumnVector (void) : MArray () { } + ColumnVector (int n) : MArray (n) { } + ColumnVector (int n, double val) : MArray (n, val) { } + ColumnVector (const MArray& a) : MArray (a) { } + ColumnVector (const ColumnVector& a) : MArray (a) { } ColumnVector& operator = (const ColumnVector& a) { - Array::operator = (a); + MArray::operator = (a); return *this; } @@ -97,17 +97,9 @@ friend ostream& operator << (ostream& os, const ColumnVector& a); friend istream& operator >> (istream& is, ColumnVector& a); -#define KLUDGE_VECTORS -#define TYPE double -#define KL_VEC_TYPE ColumnVector -#include "mx-kludge.h" -#undef KLUDGE_VECTORS -#undef TYPE -#undef KL_VEC_TYPE - private: - ColumnVector (double *d, int l) : Array (d, l) { } + ColumnVector (double *d, int l) : MArray (d, l) { } }; } // extern "C++" diff -r 9689615b34f2 -r 0bf4d2b7def4 liboctave/dDiagMatrix.cc --- a/liboctave/dDiagMatrix.cc Thu Apr 06 02:25:28 1995 +0000 +++ b/liboctave/dDiagMatrix.cc Thu Apr 06 02:35:53 1995 +0000 @@ -37,14 +37,6 @@ * Diagonal Matrix class. */ -#define KLUDGE_DIAG_MATRICES -#define TYPE double -#define KL_DMAT_TYPE DiagMatrix -#include "mx-kludge.cc" -#undef KLUDGE_DIAG_MATRICES -#undef TYPE -#undef KL_DMAT_TYPE - int DiagMatrix::operator == (const DiagMatrix& a) const { diff -r 9689615b34f2 -r 0bf4d2b7def4 liboctave/dDiagMatrix.h --- a/liboctave/dDiagMatrix.h Thu Apr 06 02:25:28 1995 +0000 +++ b/liboctave/dDiagMatrix.h Thu Apr 06 02:35:53 1995 +0000 @@ -24,7 +24,7 @@ #if !defined (octave_DiagMatrix_h) #define octave_DiagMatrix_h 1 -#include "Array.h" +#include "MArray.h" #include "dRowVector.h" #include "dColVector.h" @@ -33,32 +33,30 @@ extern "C++" { -class DiagMatrix : public DiagArray +class DiagMatrix : public MDiagArray { friend class SVD; friend class ComplexSVD; public: - DiagMatrix (void) : DiagArray () { } - DiagMatrix (int n) : DiagArray (n) { } - DiagMatrix (int n, double val) : DiagArray (n, val) { } - DiagMatrix (int r, int c) : DiagArray (r, c) { } - DiagMatrix (int r, int c, double val) : DiagArray (r, c, val) { } - DiagMatrix (const RowVector& a) : DiagArray (a) { } - DiagMatrix (const ColumnVector& a) : DiagArray (a) { } - DiagMatrix (const DiagArray& a) : DiagArray (a) { } - DiagMatrix (const DiagMatrix& a) : DiagArray (a) { } -// DiagMatrix (double a) : DiagArray (1, a) { } + DiagMatrix (void) : MDiagArray () { } + DiagMatrix (int n) : MDiagArray (n) { } + DiagMatrix (int n, double val) : MDiagArray (n, val) { } + DiagMatrix (int r, int c) : MDiagArray (r, c) { } + DiagMatrix (int r, int c, double val) : MDiagArray (r, c, val) { } + DiagMatrix (const RowVector& a) : MDiagArray (a) { } + DiagMatrix (const ColumnVector& a) : MDiagArray (a) { } + DiagMatrix (const MDiagArray& a) : MDiagArray (a) { } + DiagMatrix (const DiagMatrix& a) : MDiagArray (a) { } +// DiagMatrix (double a) : MDiagArray (1, a) { } DiagMatrix& operator = (const DiagMatrix& a) { - DiagArray::operator = (a); + MDiagArray::operator = (a); return *this; } -// operator DiagArray& () const { return *this; } - int operator == (const DiagMatrix& a) const; int operator != (const DiagMatrix& a) const; @@ -108,17 +106,9 @@ friend ostream& operator << (ostream& os, const DiagMatrix& a); -#define KLUDGE_DIAG_MATRICES -#define TYPE double -#define KL_DMAT_TYPE DiagMatrix -#include "mx-kludge.h" -#undef KLUDGE_DIAG_MATRICES -#undef TYPE -#undef KL_DMAT_TYPE - private: - DiagMatrix (double *d, int nr, int nc) : DiagArray (d, nr, nc) { } + DiagMatrix (double *d, int nr, int nc) : MDiagArray (d, nr, nc) { } }; } // extern "C++" diff -r 9689615b34f2 -r 0bf4d2b7def4 liboctave/dMatrix.cc --- a/liboctave/dMatrix.cc Thu Apr 06 02:25:28 1995 +0000 +++ b/liboctave/dMatrix.cc Thu Apr 06 02:35:53 1995 +0000 @@ -75,20 +75,12 @@ int F77_FCN (cfftb) (const int*, Complex*, Complex*); } -#define KLUDGE_MATRICES -#define TYPE double -#define KL_MAT_TYPE Matrix -#include "mx-kludge.cc" -#undef KLUDGE_MATRICES -#undef TYPE -#undef KL_MAT_TYPE - /* * Matrix class. */ Matrix::Matrix (const DiagMatrix& a) - : Array2 (a.rows (), a.cols (), 0.0) + : MArray2 (a.rows (), a.cols (), 0.0) { for (int i = 0; i < a.length (); i++) elem (i, i) = a.elem (i, i); diff -r 9689615b34f2 -r 0bf4d2b7def4 liboctave/dMatrix.h --- a/liboctave/dMatrix.h Thu Apr 06 02:25:28 1995 +0000 +++ b/liboctave/dMatrix.h Thu Apr 06 02:35:53 1995 +0000 @@ -27,13 +27,13 @@ // For FILE... #include -#include "Array.h" +#include "MArray.h" #include "mx-defs.h" extern "C++" { -class Matrix : public Array2 +class Matrix : public MArray2 { friend class ComplexMatrix; friend class AEPBAL; @@ -48,17 +48,17 @@ public: - Matrix (void) : Array2 () { } - Matrix (int r, int c) : Array2 (r, c) { } - Matrix (int r, int c, double val) : Array2 (r, c, val) { } - Matrix (const Array2& a) : Array2 (a) { } - Matrix (const Matrix& a) : Array2 (a) { } - Matrix (const DiagArray& a) : Array2 (a) { } + Matrix (void) : MArray2 () { } + Matrix (int r, int c) : MArray2 (r, c) { } + Matrix (int r, int c, double val) : MArray2 (r, c, val) { } + Matrix (const MArray2& a) : MArray2 (a) { } + Matrix (const Matrix& a) : MArray2 (a) { } + Matrix (const MDiagArray& a) : MArray2 (a) { } Matrix (const DiagMatrix& a); Matrix& operator = (const Matrix& a) { - Array2::operator = (a); + MArray2::operator = (a); return *this; } @@ -233,17 +233,9 @@ // Until templates really work with g++: -#define KLUDGE_MATRICES -#define TYPE double -#define KL_MAT_TYPE Matrix -#include "mx-kludge.h" -#undef KLUDGE_MATRICES -#undef TYPE -#undef KL_MAT_TYPE - private: - Matrix (double *d, int r, int c) : Array2 (d, r, c) { } + Matrix (double *d, int r, int c) : MArray2 (d, r, c) { } }; } // extern "C++" diff -r 9689615b34f2 -r 0bf4d2b7def4 liboctave/dRowVector.cc --- a/liboctave/dRowVector.cc Thu Apr 06 02:25:28 1995 +0000 +++ b/liboctave/dRowVector.cc Thu Apr 06 02:35:53 1995 +0000 @@ -51,14 +51,6 @@ * Row Vector class. */ -#define KLUDGE_VECTORS -#define TYPE double -#define KL_VEC_TYPE RowVector -#include "mx-kludge.cc" -#undef KLUDGE_VECTORS -#undef TYPE -#undef KL_VEC_TYPE - int RowVector::operator == (const RowVector& a) const { diff -r 9689615b34f2 -r 0bf4d2b7def4 liboctave/dRowVector.h --- a/liboctave/dRowVector.h Thu Apr 06 02:25:28 1995 +0000 +++ b/liboctave/dRowVector.h Thu Apr 06 02:35:53 1995 +0000 @@ -24,27 +24,27 @@ #if !defined (octave_RowVector_h) #define octave_RowVector_h 1 -#include "Array.h" +#include "MArray.h" #include "mx-defs.h" extern "C++" { -class RowVector : public Array +class RowVector : public MArray { friend class ColumnVector; public: - RowVector (void) : Array () { } - RowVector (int n) : Array (n) { } - RowVector (int n, double val) : Array (n, val) { } - RowVector (const Array& a) : Array (a) { } - RowVector (const RowVector& a) : Array (a) { } + RowVector (void) : MArray () { } + RowVector (int n) : MArray (n) { } + RowVector (int n, double val) : MArray (n, val) { } + RowVector (const MArray& a) : MArray (a) { } + RowVector (const RowVector& a) : MArray (a) { } RowVector& operator = (const RowVector& a) { - Array::operator = (a); + MArray::operator = (a); return *this; } @@ -92,17 +92,9 @@ friend ostream& operator << (ostream& os, const RowVector& a); friend istream& operator >> (istream& is, RowVector& a); -#define KLUDGE_VECTORS -#define TYPE double -#define KL_VEC_TYPE RowVector -#include "mx-kludge.h" -#undef KLUDGE_VECTORS -#undef TYPE -#undef KL_VEC_TYPE - private: - RowVector (double *d, int l) : Array (d, l) { } + RowVector (double *d, int l) : MArray (d, l) { } }; // row vector by column vector -> scalar