]> www.ginac.de Git - ginac.git/commitdiff
- made nops() return unsigned instead of int
authorRichard Kreckel <Richard.Kreckel@uni-mainz.de>
Tue, 11 Jan 2000 22:49:07 +0000 (22:49 +0000)
committerRichard Kreckel <Richard.Kreckel@uni-mainz.de>
Tue, 11 Jan 2000 22:49:07 +0000 (22:49 +0000)
ginac/container.pl
ginac/function.pl

index d89685bc5a6b18312148295f4b8f0ee3a1b0ca86..5979038d3dcfee3ad8013930d07c20d8e39324c2 100755 (executable)
@@ -181,7 +181,7 @@ public:
     void print(ostream & os, unsigned upper_precedence=0) const;
     void printtree(ostream & os, unsigned indent) const;
     bool info(unsigned inf) const;
     void print(ostream & os, unsigned upper_precedence=0) const;
     void printtree(ostream & os, unsigned indent) const;
     bool info(unsigned inf) const;
-    int nops() const;
+    unsigned nops() const;
     ex & let_op(int const i);
     ex expand(unsigned options=0) const;
     bool has(ex const & other) const;
     ex & let_op(int const i);
     ex expand(unsigned options=0) const;
     bool has(ex const & other) const;
@@ -544,7 +544,7 @@ void ${CONTAINER}::printtree(ostream & os, unsigned indent) const
 
 // ${CONTAINER}::info() will be implemented by user elsewhere";
 
 
 // ${CONTAINER}::info() will be implemented by user elsewhere";
 
-int ${CONTAINER}::nops() const
+unsigned ${CONTAINER}::nops() const
 {
     return seq.size();
 }
 {
     return seq.size();
 }
index 250bf767e13d4d518bb8e1f9b3dbd7db08b06ae8..f08990d9fdd47b636a54835632a003943a1282c1 100755 (executable)
@@ -519,7 +519,7 @@ void function::printtree(ostream & os, unsigned indent) const
        << ", hash=" << hashvalue << " (0x" << hex << hashvalue << dec << ")"
        << ", flags=" << flags
        << ", nops=" << nops() << endl;
        << ", hash=" << hashvalue << " (0x" << hex << hashvalue << dec << ")"
        << ", flags=" << flags
        << ", nops=" << nops() << endl;
-    for (int i=0; i<nops(); ++i) {
+    for (unsigned i=0; i<nops(); ++i) {
         seq[i].printtree(os,indent+delta_indent);
     }
     os << string(indent+delta_indent,' ') << "=====" << endl;
         seq[i].printtree(os,indent+delta_indent);
     }
     os << string(indent+delta_indent,' ') << "=====" << endl;