sum: extra dynamic evaluation?



Hi,

I was told that the following might be a bug in "sum".
It seems to do an extra evaluation, which causes unexpected results.

In the following code, users of the function "f" should not expect it to
behave differently when the "dummy variable"'s name is "x" than when
it's "t".

 Note that this does not happen for finite sums.

    regards,
        Amit Aronovitch

--- pls read the following with fixed width font ----->

Maxima 5.10.0 http://maxima.sourceforge.net
Using Lisp GNU Common Lisp (GCL) GCL 2.6.7 (aka GCL)
Distributed under the GNU Public License. See the file COPYING.
Dedicated to the memory of William Schelter.
This is a development version of Maxima. The function bug_report()
provides bug reporting information.
(%i1) f(x):= sum(x^n/n!,n,0,inf);
                                       n
                                      x
(%o1)                     f(x) := sum(--, n, 0, inf)
                                      n!
(%i2) f(2*t); /* result as expected: */
                                  inf
                                  ====   n  n
                                  \     2  t
(%o2)                              >    -----
                                  /      n!
                                  ====
                                  n = 0
(%i3) f(2*x); /* this is weird: */
                                  inf
                                  ====   n  n
                                  \     4  x
(%o3)                              >    -----
                                  /      n!
                                  ====
                                  n = 0
(%i4)