sympy/sympy — pull request #1011 by ellisonbg (2012-01-22 22:25:46+00:00)
Title: Fixing issue 2974 where qapply_Mul was being passed a non Mul.

This fixes this issue:

http://code.google.com/p/sympy/issues/detail?id=2974

Basically qapply is called recursively on Mul instances, but it was calling itself with a non-Mul in certain cases. Now we make sure it is always passed a Mul on the front and back sides.