Skip to content

Commit b85f760

Browse files
author
Matthias Koeppe
committed
Remove uses of sage.PACKAGE.all... (fixup)
1 parent 7ee559e commit b85f760

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

src/sage/rings/integer.pyx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -153,8 +153,6 @@ from cysignals.signals cimport sig_on, sig_off, sig_check, sig_occurred
153153

154154
import operator
155155

156-
import sage.arith.misc
157-
158156
from sage.ext.stdsage cimport PY_NEW
159157
from sage.cpython.python_debug cimport if_Py_TRACE_REFS_then_PyObject_INIT
160158

@@ -4078,7 +4076,9 @@ cdef class Integer(sage.structure.element.EuclideanDomainElement):
40784076
"""
40794077
if self.is_zero():
40804078
raise ArithmeticError("support of 0 not defined")
4081-
return sage.arith.misc.prime_factors(self)
4079+
from sage.arith.misc import prime_factors
4080+
4081+
return prime_factors(self)
40824082

40834083
def coprime_integers(self, m):
40844084
"""

src/sage/rings/rational.pyx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,6 @@ import fractions
6868
import sage.rings.rational_field
6969

7070
from sage.arith.long cimport integer_check_long_py
71-
from sage.arith.misc import prime_factors
7271
from sage.categories.morphism cimport Morphism
7372
from sage.categories.map cimport Map
7473
from sage.cpython.string cimport char_to_str, str_to_bytes
@@ -3119,6 +3118,8 @@ cdef class Rational(sage.structure.element.FieldElement):
31193118
"""
31203119
if self.is_zero():
31213120
raise ArithmeticError("Support of 0 not defined.")
3121+
from sage.arith.misc import prime_factors
3122+
31223123
return prime_factors(self)
31233124

31243125
def log(self, m=None, prec=None):

0 commit comments

Comments
 (0)