Skip to content
This repository has been archived by the owner on Jan 30, 2023. It is now read-only.

Commit

Permalink
removed deprecations
Browse files Browse the repository at this point in the history
remove deprecation of the inteface, and the one
of the obsolete parameter
  • Loading branch information
dimpase committed Nov 16, 2021
1 parent 1e24a4a commit a660ee4
Showing 1 changed file with 0 additions and 20 deletions.
20 changes: 0 additions & 20 deletions src/sage/interfaces/primecount.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,6 @@ from libcpp.string cimport string as cppstring
from cpython.int cimport PyInt_FromString

from cysignals.signals cimport sig_on, sig_off


from sage.misc.superseded import deprecation
deprecation(32412, "the module sage.interfaces.primecount is deprecated")


cimport sage.libs.primecount as primecount

cdef inline int _do_sig(int64_t n):
Expand All @@ -37,29 +31,15 @@ cpdef int64_t prime_pi(int64_t n, method=None) except -1:
- ``n`` - an integer
- ``method`` - deprecated, no longer supported in primecount 5
EXAMPLES::
sage: from sage.interfaces.primecount import prime_pi
doctest:warning
...
DeprecationWarning: the module sage.interfaces.primecount is deprecated
See https://trac.sagemath.org/32412 for details.
sage: prime_pi(1000) == 168
True
sage: prime_pi(1000, method='deleglise_rivat') == 168
doctest:warning
...
DeprecationWarning: primecount 5 no longer supports the 'method' parameter
See https://trac.sagemath.org/28493 for details.
True
"""
cdef int64_t ans
if method is not None:
from sage.misc.superseded import deprecation_cython as deprecation
deprecation(28493, "primecount 5 no longer supports the 'method' parameter")
if _do_sig(n): sig_on()
ans = primecount.pi(n)
if _do_sig(n): sig_off()
Expand Down

0 comments on commit a660ee4

Please sign in to comment.