diff options
author | Guido van Rossum <guido@python.org> | 1990-11-18 17:36:45 (GMT) |
---|---|---|
committer | Guido van Rossum <guido@python.org> | 1990-11-18 17:36:45 (GMT) |
commit | eb38d2411c9ed3c1aeedc974e20e20a95c87427e (patch) | |
tree | 22d0df8aa2a841e3d5c9d88a1e4d039bd9ea068b /Modules/mathmodule.c | |
parent | 330497564798cd231b8bac991c35807b131d9a56 (diff) | |
download | cpython-eb38d2411c9ed3c1aeedc974e20e20a95c87427e.zip cpython-eb38d2411c9ed3c1aeedc974e20e20a95c87427e.tar.gz cpython-eb38d2411c9ed3c1aeedc974e20e20a95c87427e.tar.bz2 |
DECREF pi and e after inserting in symbol table.
Diffstat (limited to 'Modules/mathmodule.c')
-rw-r--r-- | Modules/mathmodule.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/Modules/mathmodule.c b/Modules/mathmodule.c index 93b24fc..218658f 100644 --- a/Modules/mathmodule.c +++ b/Modules/mathmodule.c @@ -153,6 +153,8 @@ initmath() m = initmodule("math", math_methods); d = getmoduledict(m); - dictinsert(d, "pi", newfloatobject(atan(1.0) * 4.0)); - dictinsert(d, "e", newfloatobject(exp(1.0))); + dictinsert(d, "pi", v = newfloatobject(atan(1.0) * 4.0)); + DECREF(v); + dictinsert(d, "e", v = newfloatobject(exp(1.0))); + DECREF(v); } |