* Implementation of GiNaC's non-commutative products of expressions. */
/*
- * GiNaC Copyright (C) 1999-2000 Johannes Gutenberg University Mainz, Germany
+ * GiNaC Copyright (C) 1999-2001 Johannes Gutenberg University Mainz, Germany
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
tinfo_key = TINFO_ncmul;
}
-ncmul::~ncmul()
-{
- debugmsg("ncmul destructor",LOGLEVEL_DESTRUCT);
- destroy(false);
-}
-
-ncmul::ncmul(const ncmul & other)
-{
- debugmsg("ncmul copy constructor",LOGLEVEL_CONSTRUCT);
- copy(other);
-}
-
-const ncmul & ncmul::operator=(const ncmul & other)
-{
- debugmsg("ncmul operator=",LOGLEVEL_ASSIGNMENT);
- if (this != &other) {
- destroy(true);
- copy(other);
- }
- return *this;
-}
-
// protected
void ncmul::copy(const ncmul & other)
// public
-basic * ncmul::duplicate() const
-{
- debugmsg("ncmul duplicate",LOGLEVEL_ASSIGNMENT);
- return new ncmul(*this);
-}
-
void ncmul::print(std::ostream & os, unsigned upper_precedence) const
{
debugmsg("ncmul print",LOGLEVEL_PRINT);
void ncmul::printraw(std::ostream & os) const
{
debugmsg("ncmul printraw",LOGLEVEL_PRINT);
-
os << "%(";
for (exvector::const_iterator it=seq.begin(); it!=seq.end(); ++it) {
(*it).bp->printraw(os);
os << ")";
}
-void ncmul::printcsrc(std::ostream & os, unsigned upper_precedence) const
+void ncmul::printcsrc(std::ostream & os, unsigned type, unsigned upper_precedence) const
{
debugmsg("ncmul print csrc",LOGLEVEL_PRINT);
exvector::const_iterator it;
unsigned ncmul::precedence=50;
-
-//////////
-// global constants
-//////////
-
-const ncmul some_ncmul;
-const type_info & typeid_ncmul=typeid(some_ncmul);
-
//////////
// friend functions
//////////