X-Git-Url: https://ginac.de/ginac.git//ginac.git?a=blobdiff_plain;f=ginac%2Fpolynomial%2Fcollect_vargs.cpp;h=661372d1d43ed580cfb2a9f691a8e510a2672146;hb=82df71852;hp=acae53e6abdf2f65b18eae4b7c0a5bbd04c539ed;hpb=5ac42bdaa20f48de408f12db671d4e69ac9987da;p=ginac.git diff --git a/ginac/polynomial/collect_vargs.cpp b/ginac/polynomial/collect_vargs.cpp index acae53e6..661372d1 100644 --- a/ginac/polynomial/collect_vargs.cpp +++ b/ginac/polynomial/collect_vargs.cpp @@ -3,7 +3,7 @@ * Utility functions. */ /* - * GiNaC Copyright (C) 1999-2010 Johannes Gutenberg University Mainz, Germany + * GiNaC Copyright (C) 1999-2015 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 @@ -139,8 +139,8 @@ static void wipe_out_zeros(ex_collect_priv_t& m) } } -GiNaC::ex -ex_collect_to_ex(const ex_collect_t& ec, const GiNaC::exvector& vars) +ex +ex_collect_to_ex(const ex_collect_t& ec, const exvector& vars) { exvector ev; ev.reserve(ec.size()); @@ -155,13 +155,13 @@ ex_collect_to_ex(const ex_collect_t& ec, const GiNaC::exvector& vars) "expression has " << exp_vector.size() << " instead"); if (exp_vector[j] != 0) - tv.push_back(power(vars[j], exp_vector[j])); + tv.push_back(pow(vars[j], exp_vector[j])); } tv.push_back(ec[i].second); - ex tmp = (new mul(tv))->setflag(status_flags::dynallocated); + ex tmp = dynallocate(tv); ev.push_back(tmp); } - ex ret = (new add(ev))->setflag(status_flags::dynallocated); + ex ret = dynallocate(ev); return ret; }