]> www.ginac.de Git - ginac.git/blobdiff - ginac/operators.cpp
Use C++11 'nullptr' where applicable.
[ginac.git] / ginac / operators.cpp
index 52a84641ef773d7b3f9b99092b1415fe1a010239..31527411645c8c30f0b5718fd271e6cdf15bbd14 100644 (file)
@@ -334,7 +334,7 @@ static inline unsigned get_print_options(std::ios_base & s)
 static void set_print_options(std::ostream & s, unsigned options)
 {
        print_context *p = get_print_context(s);
-       if (p == 0)
+       if (p == nullptr)
                set_print_context(s, print_dflt(s, options));
        else
                p->options = options;
@@ -343,7 +343,7 @@ static void set_print_options(std::ostream & s, unsigned options)
 std::ostream & operator<<(std::ostream & os, const ex & e)
 {
        print_context *p = get_print_context(os);
-       if (p == 0)
+       if (p == nullptr)
                e.print(print_dflt(os));
        else
                e.print(*p);
@@ -363,7 +363,7 @@ std::ostream & operator<<(std::ostream & os, const exvector & e)
 
        os << "[";
        while (true) {
-               if (p == 0)
+               if (p == nullptr)
                        i -> print(print_dflt(os));
                else
                        i -> print(*p);
@@ -390,7 +390,7 @@ std::ostream & operator<<(std::ostream & os, const exset & e)
 
        os << "<";
        while (true) {
-               if (p == 0)
+               if (p == nullptr)
                        i->print(print_dflt(os));
                else
                        i->print(*p);
@@ -417,12 +417,12 @@ std::ostream & operator<<(std::ostream & os, const exmap & e)
 
        os << "{";
        while (true) {
-               if (p == 0)
+               if (p == nullptr)
                        i->first.print(print_dflt(os));
                else
                        i->first.print(*p);
                os << "==";
-               if (p == 0)
+               if (p == nullptr)
                        i->second.print(print_dflt(os));
                else
                        i->second.print(*p);