X-Git-Url: https://www.ginac.de/ginac.git//ginac.git?p=ginac.git;a=blobdiff_plain;f=ginac%2Fmatrix.cpp;h=380a45e718b047a9c44db0bf2aa980813d03d012;hp=cc80f7cae43b66d1223f0364acdac57ba533cf9f;hb=9c91319253425e66f9b6feb9e7036f841bc55e84;hpb=f4ecccb36c004d05fcd3f96003c56e5a70ba38dc diff --git a/ginac/matrix.cpp b/ginac/matrix.cpp index cc80f7ca..380a45e7 100644 --- a/ginac/matrix.cpp +++ b/ginac/matrix.cpp @@ -44,8 +44,6 @@ GINAC_IMPLEMENT_REGISTERED_CLASS(matrix, basic) // default ctor, dtor, copy ctor, assignment operator and helpers: ////////// -// public - /** Default ctor. Initializes to 1 x 1-dimensional zero-matrix. */ matrix::matrix() : inherited(TINFO_matrix), row(1), col(1) { @@ -53,9 +51,6 @@ matrix::matrix() : inherited(TINFO_matrix), row(1), col(1) m.push_back(_ex0()); } -// protected - -/** For use by copy ctor and assignment operator. */ void matrix::copy(const matrix & other) { inherited::copy(other); @@ -64,10 +59,7 @@ void matrix::copy(const matrix & other) m = other.m; // STL's vector copying invoked here } -void matrix::destroy(bool call_parent) -{ - if (call_parent) inherited::destroy(call_parent); -} +DEFAULT_DESTROY(matrix) ////////// // other ctors @@ -118,7 +110,6 @@ matrix::matrix(unsigned r, unsigned c, const lst & l) // archiving ////////// -/** Construct object from archive_node. */ matrix::matrix(const archive_node &n, const lst &sym_lst) : inherited(n, sym_lst) { debugmsg("matrix ctor from archive_node", LOGLEVEL_CONSTRUCT); @@ -134,13 +125,6 @@ matrix::matrix(const archive_node &n, const lst &sym_lst) : inherited(n, sym_lst } } -/** Unarchive the object. */ -ex matrix::unarchive(const archive_node &n, const lst &sym_lst) -{ - return (new matrix(n, sym_lst))->setflag(status_flags::dynallocated); -} - -/** Archive the object. */ void matrix::archive(archive_node &n) const { inherited::archive(n); @@ -153,6 +137,8 @@ void matrix::archive(archive_node &n) const } } +DEFAULT_UNARCHIVE(matrix) + ////////// // functions overriding virtual functions from bases classes //////////