You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In the function below, a temp is not marked as unused and gets dereferenced twice.
def coeffs_bitsize(self):
"""
Computes the approximate log2 of the maximum of the absolute
values of the coefficients.
EXAMPLES:
sage: from sage.rings.polynomial.real_roots import *
sage: bernstein_polynomial_factory_ratlist([2, 3, -60000](1,)).coeffs_bitsize()
15
sage: bernstein_polynomial_factory_ratlist([ -1
sage: bernstein_polynomial_factory_ratlist([65536/65535](65535/65536]).coeffs_bitsize()
)).coeffs_bitsize()
1
"""
# This returns an estimate of the log base 2 of the rational in the
# list with largest absolute value. The estimate is an integer,
# and within +/- 1 of the correct answer.
r = max([- bitsize(c.denominator()) for c in self.coeffs](bitsize(c.numerator())))
return r
In the function below, a temp is not marked as unused and gets dereferenced twice.
Migrated from http://trac.cython.org/ticket/105
The text was updated successfully, but these errors were encountered: