Fix Issue 3594 (factor should return unhandled expr unchanged)
Merge branch 'master' of https://github.com/shaunheilee/sympy