#include <ginac/basic.h>
#include <ginac/operators.h>
+#ifndef NO_GINAC_NAMESPACE
namespace GiNaC {
+#endif // ndef NO_GINAC_NAMESPACE
class ex;
class expand_options;
class symbol;
class lst;
-typedef vector<ex> exvector;
+// typedef vector<ex> exvector;
// enum definitions
#ifdef INLINE_EX_CONSTRUCTORS
: bp(exZERO().bp)
{
- ASSERT(exZERO().bp!=0);
- ASSERT(exZERO().bp->flags & status_flags::dynallocated);
- ASSERT(bp!=0);
+ GINAC_ASSERT(exZERO().bp!=0);
+ GINAC_ASSERT(exZERO().bp->flags & status_flags::dynallocated);
+ GINAC_ASSERT(bp!=0);
++bp->refcount;
}
#else
~ex()
#ifdef INLINE_EX_CONSTRUCTORS
{
- ASSERT(bp!=0);
- ASSERT(bp->flags & status_flags::dynallocated);
+ GINAC_ASSERT(bp!=0);
+ GINAC_ASSERT(bp->flags & status_flags::dynallocated);
if (--bp->refcount == 0) {
delete bp;
}
#ifdef INLINE_EX_CONSTRUCTORS
: bp(other.bp)
{
- ASSERT(bp!=0);
- ASSERT((bp->flags) & status_flags::dynallocated);
+ GINAC_ASSERT(bp!=0);
+ GINAC_ASSERT((bp->flags) & status_flags::dynallocated);
++bp->refcount;
}
#else
ex const & operator=(ex const & other)
#ifdef INLINE_EX_CONSTRUCTORS
{
- ASSERT(bp!=0);
- ASSERT(bp->flags & status_flags::dynallocated);
- ASSERT(other.bp!=0);
- ASSERT(other.bp->flags & status_flags::dynallocated);
+ GINAC_ASSERT(bp!=0);
+ GINAC_ASSERT(bp->flags & status_flags::dynallocated);
+ GINAC_ASSERT(other.bp!=0);
+ GINAC_ASSERT(other.bp->flags & status_flags::dynallocated);
++other.bp->refcount;
basic * tmpbp=other.bp;
if (--bp->refcount==0) {
int compare(ex const & other) const
#ifdef INLINE_EX_CONSTRUCTORS
{
- ASSERT(bp!=0);
- ASSERT(other.bp!=0);
+ GINAC_ASSERT(bp!=0);
+ GINAC_ASSERT(other.bp!=0);
if (bp==other.bp) {
// special case: both expression point to same basic, trivially equal
return 0;
bool is_equal(ex const & other) const
#ifdef INLINE_EX_CONSTRUCTORS
{
- ASSERT(bp!=0);
- ASSERT(other.bp!=0);
+ GINAC_ASSERT(bp!=0);
+ GINAC_ASSERT(other.bp!=0);
if (bp==other.bp) {
// special case: both expression point to same basic, trivially equal
return true;
inline void swap(ex & e1, ex & e2)
{ e1.swap(e2); }
+#ifndef NO_GINAC_NAMESPACE
} // namespace GiNaC
+#endif // ndef NO_GINAC_NAMESPACE
#endif // ndef __GINAC_EX_H__
+