]> www.ginac.de Git - ginac.git/blobdiff - ginac/expairseq.cpp
Improve method of setting status_flags::dynallocated.
[ginac.git] / ginac / expairseq.cpp
index 7168d279dfe1dfbc661cdf7aa618afc4007e5a86..84b756f9d762e64721bd612485b8be4622a9706c 100644 (file)
@@ -246,7 +246,7 @@ ex expairseq::eval(int level) const
 
        epvector evaled = evalchildren(level);
        if (!evaled.empty())
-               return (new expairseq(std::move(evaled), overall_coeff))->setflag(status_flags::dynallocated | status_flags::evaluated);
+               return dynallocate<expairseq>(std::move(evaled), overall_coeff).setflag(status_flags::evaluated);
        else
                return this->hold();
 }
@@ -560,7 +560,7 @@ expair expairseq::combine_pair_with_coeff_to_pair(const expair &p,
  *  @see expairseq::split_ex_to_pair() */
 ex expairseq::recombine_pair_to_ex(const expair &p) const
 {
-       return lst(p.rest,p.coeff);
+       return lst{p.rest, p.coeff};
 }
 
 bool expairseq::expair_needs_further_processing(epp it)