From: Richard Kreckel Date: Fri, 13 Apr 2001 18:27:34 +0000 (+0000) Subject: * add::print() shouldn't put parens around overall_coeff. X-Git-Tag: release_0-8-1~10 X-Git-Url: https://www.ginac.de/ginac.git//ginac.git?p=ginac.git;a=commitdiff_plain;h=d9927cf4bc27d542d5f6487d31f5d43dc2e39af7 * add::print() shouldn't put parens around overall_coeff. --- diff --git a/ginac/add.cpp b/ginac/add.cpp index cfcae9bc..802c2372 100644 --- a/ginac/add.cpp +++ b/ginac/add.cpp @@ -174,7 +174,10 @@ void add::print(const print_context & c, unsigned level) const // First print the overall numeric coefficient, if present if (!overall_coeff.is_zero()) { - overall_coeff.print(c, precedence); + if (!is_of_type(c, print_tree)) + overall_coeff.print(c, 0); + else + overall_coeff.print(c, precedence); first = false; }