]> www.ginac.de Git - ginac.git/commitdiff
Synced to HEAD:
authorJens Vollinga <vollinga@thep.physik.uni-mainz.de>
Mon, 27 Aug 2007 16:36:13 +0000 (16:36 +0000)
committerJens Vollinga <vollinga@thep.physik.uni-mainz.de>
Mon, 27 Aug 2007 16:36:13 +0000 (16:36 +0000)
info_flags::expanded added [A.Sheplyakov]

ginac/expairseq.cpp
ginac/flags.h
ginac/numeric.cpp
ginac/power.cpp
ginac/symbol.cpp

index f7a54bc04f11a217746dcb2b815a35cb2aef02d1..be8790f00559f73e288398ee80d2a1c7deecfe9d 100644 (file)
@@ -261,6 +261,8 @@ void expairseq::do_print_tree(const print_tree & c, unsigned level) const
 
 bool expairseq::info(unsigned inf) const
 {
+       if (inf == info_flags::expanded)
+               return (flags & status_flags::expanded);
        return inherited::info(inf);
 }
 
index fbbd0410c0e2a19931eeff527ed3c4551ed812dc..a42f869d6c69a850db7a2f1a19a904a2ce3ac26c 100644 (file)
@@ -236,7 +236,10 @@ public:
                has_indices,  // object has at least one index
 
                // answered by class idx
-               idx
+               idx,
+
+               // answered by classes numeric, symbol, add, mul, power
+               expanded
        };
 };
 
index 81f285b5bbbce7f9cf6baf02ac0845744009450f..208a89c0d935462d0dce3a66fef0422cfd9a7b87 100644 (file)
@@ -576,6 +576,7 @@ bool numeric::info(unsigned inf) const
                case info_flags::numeric:
                case info_flags::polynomial:
                case info_flags::rational_function:
+               case info_flags::expanded:
                        return true;
                case info_flags::real:
                        return is_real();
index 0dfbc8fe908bc219b67aad40959796a22ebdb872..13d8c5503e9b0609ad0a2e4df01df7a7cd4fa569 100644 (file)
@@ -230,6 +230,8 @@ bool power::info(unsigned inf) const
                case info_flags::algebraic:
                        return !exponent.info(info_flags::integer) ||
                               basis.info(inf);
+               case info_flags::expanded:
+                       return (flags & status_flags::expanded);
        }
        return inherited::info(inf);
 }
index b1f922edab710bb0d99b7fa92a07e966c177835e..2edd7149adb1f195a35625d09031013fdd886d4f 100644 (file)
@@ -197,7 +197,8 @@ bool symbol::info(unsigned inf) const
            inf == info_flags::cinteger_polynomial ||
            inf == info_flags::rational_polynomial ||
            inf == info_flags::crational_polynomial ||
-           inf == info_flags::rational_function)
+           inf == info_flags::rational_function ||
+                       inf == info_flags::expanded)
                return true;
        if (inf == info_flags::real)
                return domain == domain::real;