]> www.ginac.de Git - ginac.git/blobdiff - ginac/idx.cpp
- Importing new files for packaging Debian GNU/Linux packages.
[ginac.git] / ginac / idx.cpp
index f57a5ae4bdc6ac71067d888d37c1ddead3ca59f4..caaa79e73702a8ebd963c02c91060d4a08b1f207 100644 (file)
@@ -3,7 +3,7 @@
  *  Implementation of GiNaC's indices. */
 
 /*
- *  GiNaC Copyright (C) 1999 Johannes Gutenberg University Mainz, Germany
+ *  GiNaC Copyright (C) 1999-2000 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
@@ -29,7 +29,9 @@
 #include "utils.h"
 #include "debugmsg.h"
 
+#ifndef NO_GINAC_NAMESPACE
 namespace GiNaC {
+#endif // ndef NO_GINAC_NAMESPACE
 
 //////////
 // default constructor, destructor, copy constructor assignment operator and helpers
@@ -202,13 +204,13 @@ ex idx::subs(lst const & ls, lst const & lr) const
 {
     GINAC_ASSERT(ls.nops()==lr.nops());
 #ifdef DO_GINAC_ASSERT
-    for (int i=0; i<ls.nops(); i++) {
+    for (unsigned i=0; i<ls.nops(); i++) {
         GINAC_ASSERT(is_ex_exactly_of_type(ls.op(i),symbol)||
                is_ex_of_type(ls.op(i),idx));
     }
 #endif // def DO_GINAC_ASSERT
 
-    for (int i=0; i<ls.nops(); i++) {
+    for (unsigned i=0; i<ls.nops(); i++) {
         if (is_equal(*(ls.op(i)).bp)) {
             return lr.op(i);
         }
@@ -446,4 +448,6 @@ ex subs_indices(ex const & e, exvector const & idxv_subs,
     return res;
 }
 
+#ifndef NO_GINAC_NAMESPACE
 } // namespace GiNaC
+#endif // ndef NO_GINAC_NAMESPACE