Changeset a388ae in git for Singular/CanonicalPoly.cc
- Timestamp:
- Oct 21, 2009, 5:36:00 PM (15 years ago)
- Branches:
- (u'spielwiese', 'fe61d9c35bf7c61f2b6cbf1b56e25e2f08d536cc')
- Children:
- 9b4a332909ecddda93d19e235977388831620db1
- Parents:
- bb503c7363e3c90a3b0c5ae93374d5b7b20cc34a
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
Singular/CanonicalPoly.cc
rbb503c7 ra388ae 3 3 #ifdef HAVE_WRAPPERS 4 4 5 #include <iostream> 5 6 #include "structs.h" 6 7 #include "polys.h" 8 #include "Wrappers.h" 7 9 #include "CanonicalPoly.h" 8 #include "Wrappers.h"9 #include <iostream>10 10 11 11 CanonicalPoly::CanonicalPoly (const SingularPoly& sp, const RingWrapper& r):InternPoly(r) … … 17 17 18 18 CanonicalPoly::CanonicalPoly (const int i, const RingWrapper& r):InternPoly(r) 19 { // this method seems to work in char 0 only; is this due to a malfunction of p_ISet?19 { 20 20 +prpr > "CanonicalPoly constructor with int argument = " < i; 21 21 m_poly = p_ISet(i, r.getSingularRing()); … … 25 25 { 26 26 +prpr > "CanonicalPoly destructor, object = " < this->toString(); 27 //p_Delete(&m_poly, m_ring.getSingularRing());28 27 } 29 28 … … 36 35 void CanonicalPoly::addCompatible (const InternPoly* ip) 37 36 { 38 if (ip->getPolyType() == 1)37 if (ip->getPolyType() == CANONICAL_POLY_TYPE) 39 38 { 40 39 const CanonicalPoly* pcp = static_cast<const CanonicalPoly*>(ip); … … 49 48 } 50 49 else 51 {52 50 assume(false); 53 }54 51 } 55 52 … … 67 64 { 68 65 +prpr > "creating a deep copy of CanonicalPoly, argument = " < this->toString(); 69 SingularPoly sp = p_Copy(this->getSingularPoly(), this->getRing().getSingularRing()); // SINGULAR poly is deeply copied.70 CanonicalPoly* pcp = new CanonicalPoly(sp, this->getRing()); // ring is not deeply copied!66 SingularPoly sp = p_Copy(this->getSingularPoly(), this->getRing().getSingularRing()); /* SINGULAR poly is deeply copied. */ 67 CanonicalPoly* pcp = new CanonicalPoly(sp, this->getRing()); /* ring is not deeply copied! */ 71 68 return pcp; 72 69 } 73 70 74 #endif // HAVE_WRAPPERS 71 #endif 72 /* HAVE_WRAPPERS */
Note: See TracChangeset
for help on using the changeset viewer.