sympy/sympy — pull request #1763 by skirpichev (2013-02-08 06:54:39+00:00)
Title: Fix Integer formating in generated C code

ccode() output looks inconsistent in handling Rational and Integer numbers. Sometimes, it emits double, sometimes integer literals.

An example:
In [1]: ccode(Rational(2,3)+x)
Out[1]: x + 2.0/3.0

But:
In [2]: ccode(Rational(2,3)*x)
Out[2]: 2*x/3
In [3]: ccode(Integer(3)+x)
Out[3]: x + 3

This introduce a lot of compiler warnings for large enough integers:
wf_auto.c:445: warning: this decimal constant is unsigned only in ISO C90
wf_auto.c:445:71: warning: integer constant is too large for its type